Mass protests against the rule of Armenian ex-President and newly appointed Prime Minister Serzh Sargsyan have been ongoing in the country for the second week, with soldiers also taking to the streets earlier in the day.

"I address you for the last time as a head of state. Nikol Pashinyan was right. I made a mistake. In this situation, there are several solutions, but I will not resort to any of them. That's not my thing. I abandon the post of the head of our country," Serzh Sargsyan said as qouted by his press service.

Armenian First Deputy Prime Minister Karen Karapetyan has become acting prime minister, the government press service said in a statement Monday.

"According to the procedure adopted by the government, if the prime minister can't fulfill his duties, the prime minister is replaced by the first deputy prime minister," the statement posted on the cabinet website said.

Later in the day, Armenian President Armen Sarkissian accepted the government's resignation.

"In line with Article 13 of the Constitution, accept the resignation of the Government of the Republic of Armenia," a decree, posted on the presidential website, says.

Nikol Pashinyan, opposition's leader, was released earlier today after he had been detained on Sunday after failing to reach any deal in brief talks with Sargsyan, who called for a dialogue between the government and opposition.

READ MORE: Armenian Military Vows to Punish Soldiers Who Take Part in Protests (PHOTOS)

The protests against Sargsyan began on April 13, with the demonstrators accusing him of inefficient management and the deterioration of the economic situation in the country. On April 17, after Sargsyan, despite the ongoing unrest, had been appointed as Prime Minister of Armenia, the opposition announced the beginning of a "velvet revolution".

The backlash against his rule was triggered after Sargsyan, who served as Armenia's president from 2008, stepped down when his term ended but was subsequently nominated for the premiership, which has largely been viewed as an attempt to stay in power as a newly amended constitution transferred some of the presidential powers to the head of the government.

READ MORE: Serj Tankian Urges Armenian Protesters to Avoid 'Color Revolution Terminology'