At the St. Petersburg Economic Forum, Russian President Vladimir Putin signaled he would work with the new president in Ukraine, saying he will "respect the choice of Ukrainian people." (Reuters)

Russia will respect the result of Ukraine’s presidential election, Russian President Vladimir Putin said Friday, as fighting continued in the country’s restive eastern regions two days ahead of the crucial poll.

The conciliatory sentiment raised hopes that Russia will be willing to work with new authorities in Ukraine after months of denouncing as illegitimate the acting government that replaced pro-Kremlin president Viktor Yanukovych, who was ousted in February amid popular protests.

“We understand and see that people in Ukraine want the country to come out of this lengthy crisis,” Putin said at a conference in St. Petersburg. “We also want the situation to become calmer. We will respect the choice made by the people of Ukraine.”

He also said he hoped that his nation’s relations with the United States, currently at Cold War-era lows, improve after Ukraine’s crisis is resolved. But, he said, “we can’t force anyone to love us.”

There were reports Friday of further clashes between pro-government and anti-government militias near the eastern Ukrainian city of Donetsk, a day after intense fighting in the region killed at least 13 soldiers and raised tensions ahead of Sunday’s vote.

The Ukrainian Defense Ministry said Friday that 20 pro-Russian insurgents were killed and more than 30 wounded a day earlier when 500 rebels attacked a Ukrainian military position near the eastern town of Rubizhne. The account could not immediately be confirmed independently, and there was no explanation of why it took authorities so long to release the details. In a separate incident near the town early Friday, one soldier was killed when Ukrainian troops were ambushed by rebels, the ministry said.

Local media also reported heavy shelling Friday in the rebel stronghold of Slovyansk. A 10-minute video posted online, ostensibly from Slovyansk, showed smoke rising from points across a residential landscape amid the repetitive thuds of artillery fire.

A top Russian military commander said Russia would respond to NATO’s troop buildup in Poland and the Baltics, where alliance forces are conducting exercises. The statement by Valery Gerasimov, head of Russia’s Armed Forces General Staff, added to tensions between Russia and the West that have reached Cold War heights.

“In this situation, we cannot ignore these events. We have to take measures in response,” Gerasimov told reporters Friday at an international security conference in Moscow, Interfax reported.

The Thursday clashes prompted Ukrainian officials to call for an emergency meeting of the U.N. Security Council and broke several days of relative calm amid reports of divisions in the separatist ranks. The United States and its European allies have accused Russia of sowing chaos in eastern Ukraine to throw off the election, and they have threatened Moscow with additional sanctions if the vote is disrupted.

Acting President Oleksandr Turchynov said Thursday that the 13 Ukrainian troops were killed when rebels attacked a checkpoint with automatic weapons and rocket-propelled grenades near the town of Volnovakha, south of Donetsk. A regional health official later said that 16 people had died.

Witnesses told the Associated Press that the attackers arrived in a bank’s armored car, which the unsuspecting soldiers waved through the checkpoint, only to be mowed down at point-blank range.

The Foreign Ministry also said Ukrainian border guards repelled an attack Wednesday by “several groups of armed militants” who were trying to enter the country from Russia. Describing one of the attacks, the Interior Ministry said in a statement that three trucks and a sport-utility vehicle attempted to cross the border in the Luhansk region late Wednesday but that the border guards fired warning shots and the cars raced back into Russia.

Ukrainians are scheduled to go to the polls Sunday in presidential and mayoral elections that could determine the direction of the country and its alignment between Russia and the West.

Pro-Russian separatists in its eastern region have declared the vote illegal and been actively seeking to halt it.

At district election commission No. 42 here, for example, a group of about 10 armed men from the self-proclaimed People’s Republic of Donetsk arrived last week to tell the employees their work was done. Their message was clear: There will be no presidential election in Ukraine this Sunday if the pro-Russian separatists have their way.

“I was terrified and locked the door,” said Elvira Maslova, 51, a receptionist who works down the hall.

Separatists have targeted other election offices in the Donetsk region, which is home to about 3.5 million voters, or nearly 10 percent of the country’s voters, a regional election official said.

On Thursday, armed militants closed another of the Donetsk region’s district election commission offices, each of which organizes and oversees voting for several polling stations.

At other locations, some local officials were abducted but usually released a short time later, and at least one was beaten, said Valeriy Zhaldak, a former Ministry of Justice employee who is serving as elections adviser to Donetsk’s regional government. In the city of Horlivka, the person who was heading the district election commission apparently crossed to the separatist side and was proclaimed the “people’s mayor,” Zhaldak said.

“There are always fights somewhere,” Zhaldak said.

Zhaldak, who is working out of a hotel because pro-Russian separatists still occupy the main regional administration building, said some election offices have been relocated from hot spots, such as rebel-held Slovyansk. Some local elections officials also have agreed to hide voter records, ballot boxes and other materials in their homes.

Denis Pushilin, a leader of the People’s Republic of Donetsk who sees the national government as an occupier, said the elections are illegal in his territory but denied using violence to halt them.

“We think it’s inappropriate to hold presidential elections in a neighboring country,” he said in an interview. “As for disrupting the elections, I wouldn’t use this term. I’d say we are opposing them through civilized methods, with the help of law enforcement and police. We are not advocates of violence.”

Alexander Chernenko, who heads a nonprofit organization that trains election commissioners and monitors, said that the interim government must move faster to provide security. At least 5 percent of the region’s local election offices have been closed because of separatist threats, he said.

Ukraine’s parliament has authorized national security forces to guard election offices in areas where local police have failed to do their jobs, either because they are outgunned or sympathetic to the separatists. But Chernenko said little has been done in practice.

In the end, election officials say they must rely on the courage of people such as Aleksandr Stryuk, who is one of the district election commissioners in the office shuttered last week.

“I am a businessman and doing this job not for the money,” he said. “But the main issue is people’s lives. If security is improved, we will continue our duty.”

Kunkle reported from Donetsk. Hauslohner reported from Moscow. Daniela Deane in London and Aleksey Ryabchyn and Anastasiia Fedesova in Donetsk contributed to this report.