KHERSON, Ukraine (AP) - President Volodymyr Zelenskyy triumphantly walked the streets of the newly liberated city of Kherson on Monday, hailing Russia's withdrawal as the “beginning of the end of the war,” but also acknowledging the heavy price Ukrainian troops are paying in their grinding effort to push back the invaders.

The retaking of Kherson was one of Ukraine's biggest successes in the nearly 9-month-old war, dealing another stinging blow to the Kremlin. It could serve as a springboard for more advances into occupied territory.

President Joe Biden called it a “significant victory” for Ukraine.

“I can do nothing but applaud the courage, determination and capacity of the Ukrainian people, the Ukrainian military,” he said on the sidelines of a Group of 20 summit in Indonesia. “They've really been amazing. ... we're going to continue to provide the capability for the Ukrainian people to defend themselves.”

Large parts of eastern and southern Ukraine are still under Russian control, and the city of Kherson itself remains within reach of Moscow's shells and missiles. Heavy fighting continued elsewhere in Ukraine. Russia's state news agency RIA Novosti reported the town of Oleshky, in Russian-held territory across the Dnieper River from Kherson, came under heavy artillery fire.

Zelenskyy awarded medals to soldiers in Kherson and posed with them for selfies while striking a defiant note.

“This is the beginning of the end of the war,” he said. “We are step by step coming to all the temporarily occupied territories.”

But he also grimly noted the fighting “took the best heroes of our country.”

The end of Russia's occupation of the city - the only provincial capital seized since the February invasion - has sparked days of celebration. But as winter approaches, its remaining 80,000 residents are without heat, water and electricity, and short on food and medicine. Zelenskyy says the city is laced with booby traps and mines. And Ukrainian authorities say there are signs of atrocities emerging, just as in other liberated areas.

Russian forces “destroyed everything in their path, wrecked the entire electricity network,” he said. Communications operators said cellphone service was being restored and the regional governor said a public wireless internet access point would begin working Tuesday.

The Institute for the Study of War said Ukraine has won “an important victory” in Kherson and other areas west of the Dnieper, but the Washington-based think tank noted that “it has by no means liberated the minimum territory essential to its future security and economic survival.”

NATO Secretary-General Jens Stoltenberg warned that Moscow should not be underestimated.

“The Russian armed forces retain significant capability as well as a large number of troops, and Russia has demonstrated their willingness to bear significant losses,” he said in The Hague.

In Ankara, Turkey, CIA Director Bill Burns met with his Russian intelligence counterpart, Sergei Naryshkin, to underscore the consequences if Moscow were to deploy a nuclear weapon in Ukraine, according to a White House National Security Council official.

The official, who was not authorized to comment publicly and spoke on the condition of anonymity, said Burns and Naryshkin, the head of Russia's SVR spy agency, did not discuss settlement of the war. Their meeting was the highest-ranking face-to-face engagement between U.S. and Russian officials since before the invasion.

While U.S. officials have warned for months of the prospect that Russia could use weapons of mass destruction in Ukraine amid battlefield setbacks, Biden administration officials have repeatedly said nothing has changed in U.S. intelligence assessments to suggest that Russian President Vladimir Putin has imminent plans to deploy nuclear weapons.

The U.N. General Assembly, meanwhile, passed a resolution calling for establishing a mechanism to assess Russian reparations for damages and injuries in Ukraine. The resolution is not binding and Russia's ambassador said it had no legal validity.

Zelenskyy's trip to Kherson was another in a series of unexpected visits to front-line areas at crucial moments of the war. It was laden with symbolism and the common touch - aimed at boosting the morale of soldiers and civilians alike.

In a video, a visibly moved Zelenskyy stood with his hand on his heart and sang the national anthem as troops saluted and stood at attention and a soldier raised the yellow-and-blue Ukrainian flag.

Residents draped with flags on their shoulders cheered, cried and shouted in gratitude as Zelenskyy walked by.

“It's amazing. We've been waiting for him for nine months. Thank you,” said Danila Yuhrenko.

Serhii Yukhmchuk, 47, said he and his wife spent the occupation mostly at home to avoid any Russians and protested by refusing to use the ruble as currency.

Kremlin spokesman Dmitry Peskov refused to comment on Zelenskyy's visit, except to say: “You know that it is the territory of the Russian Federation.” Russia illegally annexed the Kherson region and three other Ukrainian provinces earlier this year, in addition to annexing the Crimean Peninsula in 2014.

In his Sunday night address, Zelenskyy said that “investigators have already documented more than 400 Russian war crimes, and the bodies of both civilians and military personnel have been found.”

“In the Kherson region, the Russian army left behind the same atrocities as in other regions of our country,” he said. “We will find and bring to justice every murderer. Without a doubt.”

Residents said Russian troops plundered the city and wrecked key infrastructure before retreating across the wide Dnieper River to its east bank last week.

Reconnecting the electricity supply is the priority, regional Gov. Yaroslav Yanushevych said.

The arrival of winter is making the situation more difficult, with Stoltenberg saying that Putin is aiming “to leave Ukraine cold and dark this winter.”

Biden said he expected things to slow down somewhat militarily “because of the winter months and the inability to move as easily around.”

In the past two months, Ukraine's military claimed to have retaken dozens of towns and villages north of the city of Kherson, a key gateway to Crimea to the south.

But the grinding war continued - with shelling, civilian casualties and each side reporting gains.

The Russian Defense Ministry said its forces had captured the village of Pavlivka in the eastern Donetsk region. Multiple Ukrainian officials have reported heavy battles there in recent weeks.

In Luhansk, another eastern region illegally annexed by Moscow, Kyiv's forces have retaken 12 settlements, said regional Gov. Serhiy Haidai.

A senior U.S. military official said missile and drone strikes have slowed down a bit in Ukraine since the end of October. The U.S. doesn't know the specific reason for the decline, the official said, but noted that Russia continues to see its weapons stockpiles decrease, particularly precision-guided munitions.

The official, who spoke on condition of anonymity to provide the U.S. military assessment, said Russia continues to hit civilian infrastructure, including the electrical grid, and the U.S. has no reason to believe Moscow will let up on its attacks any time soon.

Asked if the U.S. will scale back its weapons contributions to Kyiv as winter takes hold, and fighting is likely to level off a bit, the official said Washington will continue to work with allies to ensure it has what it needs and that air defense systems will be an ongoing priority.

Associated Press writers John Leicester in Kyiv, Hanna Arhirova in Odesa, Ukraine, and Aamer Madhani and Lolita Baldor in Washington contributed.