PRISTINA (Reuters) - Opposition lawmakers released teargas in Kosovo’s parliament and protesters outside threw petrol bombs in an unsuccessful attempt to stop Hashim Thaci, who they say gave too much power to ethnic Serbs, from being elected president.

Twenty one officers were injured in the streets of Pristina during Friday’s session when police used teargas and water cannons to disperse protesters.

Thaci, now 47, helped to clinch an EU-brokered agreement in 2015 that gives a small Serb minority more power over local government decisions and raises the possibility of financing from Belgrade.

With 71 votes in a 120-seat parliament, he will be Kosovo’s fourth president and serve five years in the largely ceremonial role.

Four hours into Friday’s session, led by Thaci’s Democratic Party of Kosovo (PDK), opposition lawmakers threw three tear gas canisters in the chamber, prompting the speaker, Kadri Veseli, to eject 11 MPs.

An hour later tear gas was thrown again but the vote was passed despite a delay.

Opposition parties have been protesting for four months against the deal with Serbia and have staged street protests, repeatedly thrown tear gas in parliament, clashed with police and last month set a government building on fire.

Slideshow ( 3 images )

Police in full riot gear backed by armored vehicles used tear gas and water cannons to disperse several hundred demonstrators.

Protesters shouted, “Hashim, Hashim we want you in jail!” and “Hashim, the traitor!”

“I will always work to serve the country, all its citizens and respect the constitution,” Thaci told the parliament after the vote.

Born and raised in the hardline region of Drenica, Thaci led the guerrilla insurgency against Serbian forces in 1998-99. He served as Kosovo’s prime minister when it declared independence in 2008.

But in a 2011 Council of Europe report he was identified as a leader of a group that had committed war crimes against Serbs and had harvested organs from Serbs captured in the 1998-99 Kosovo war.

Thaci has denied the accusations.

Kosovo declared independence from Serbia in 2008, almost a decade after NATO air strikes drove out Serbian security forces accused of killing and expelling ethnic Albanian civilians during a counter-insurgency war.

Many Kosovo Albanians believe last year’s accord with Serbia could erode that hard-won sovereignty, though its status is unclear after a Kosovo constitutional court ruling in December that parts of it breach the country’s laws.

“Our protests will not stop, they will get bigger,” Visar Ymeri, leader of the biggest opposition party Vetevendosje, told a press conference.