Syrian and Russian forces will deploy in northeast Syria to remove Kurdish YPG fighters and their weapons from the border with Turkey under a deal agreed on Tuesday which both Moscow and Ankara hailed as a triumph.The agreement expands on a U.S.-brokered truce which was set to expire late on Tuesday and underlines the dizzying changes in Syria since President Donald Trump announced a U.S. troop withdrawal two weeks ago, ahead of Turkey's cross-border offensive.Tuesday's deal endorses the return of Syrian President Bashar al-Assad's forces to the border alongside Russian troops, replacing the Americans who had patrolled the region for years with their former Kurdish allies.Under the agreement between Russian President Vladimir Putin and Turkey's Tayyip Erdogan, the two countries said Russian military police and Syrian border guards would start removing the YPG 30 km (19 miles) from the Turkish border on Wednesday.Six days later, Russian and Turkish forces will jointly start to patrol a narrower, 10 km strip of land in the "safe zone" that Ankara has long sought in northeast Syria.After six hours of talks with Erdogan in the Black Sea resort of Sochi, Putin expressed satisfaction at decisions he described as "very important, if not momentous, to resolve what is a pretty tense situation which has developed on the Syrian-Turkish border."A senior Turkish official described it as an "excellent" deal which would achieve Turkey's long-held goal of a border strip cleared of the YPG, which Ankara regards as a terrorist organization because of its links to insurgents inside Turkey.Last week's U.S.-brokered deal, due to expire at 2200 GMT on Tuesday, was limited the central part of the border strip between the Syrian towns of Tel Abyad and Ras al Ain, where Turkish forces had focused their military offensive.Under the deal with Moscow, the length of border which the YPG would be required to pull back from is more than three times the size of the territory covered by the U.S.-Turkish accord, covering most of the area Turkey had wanted to include."The outcome of the Putin-Erdogan meeting in Sochi today indicates that Erdogan has become a master of leveraging the U.S. and Russia against each other to maximize Ankara's gains," Soner Cagaptay, director of the Turkish program at the Washington Institute said in a tweet"Turkey got the safe zone it wanted all this time."KURDISH WITHDRAWALJust minutes before Erdogan and Putin annonunced their deal, a senior U.S. administration official said the commander of Kurdish forces in northeast Syria told the United States he had met all obligations set out in the U.S.-brokered truce.An official from the Syrian Democratic Forces later said the SDF commander "confirms that the SDF have withdrawn from ceasefire zone."Before flying to Russia for the talks Erdogan had said hundreds of Kurdish fighters remained near to Syria's northeast border despite the truce demanding their withdrawal.Turkey began its cross-border operation nearly two weeks ago following Trump's decision to withdraw U.S. troops from northern Syria.That withdrawal has been criticized by U.S. lawmakers, including some of Trump's fellow Republicans, as a betrayal of Kurdish allies who have helped the United States fight Islamic State in Syria.Trump said on Monday it appeared that the five-day pause was holding despite skirmishes, and that it could possibly go beyond Tuesday's expiry, but Erdogan said the fighting may resume."If the promises given to us by America are not kept, we will continue our operation from where it left off, this time with a much bigger determination," he said.Turkey sought a "safe zone" along 440 km (275 miles) of border with northeast Syria, but its assault focused on the two border towns in the center of that strip, Ras al Ain and Tel Abyad.Syrian and Russian forces have already entered two border cities, Manbij and Kobani, which lie within Turkey's planned "safe zone" but to the west of Turkey's military operations.Erdogan has said he could accept the presence of Syrian troops in those areas, as long as the YPG are pushed out.Russia is a close ally of Assad. Turkey has backed rebels seeking to oust Assad during Syria's more than eight-year-long civil war but has dropped its once-frequent calls for him to quit.Ankara is holding covert contacts with Damascus, partly via Russia, to avert direct conflict in northeast Syria, Turkish officials say, although publicly hostility between the two governments remains."Erdogan is a thief and is now stealing our land," Assad said during a rare visit to a separate frontline in Syria's northwestern Idlib region, the last major bastion of Turkey-backed rebels.Some 300,000 people have been displaced by Turkey's offensive and 120 civilians have been killed, according to the Syrian Observatory for Human Rights, a UK-based war monitor. It said on Sunday 259 fighters with the Kurdish-led forces had been killed, and 196 Turkey-backed Syrian rebels. Turkey says 765 terrorists but no civilians have been killed in its offensive.