In 2014, after seizing large parts of Syria and Iraq, the Islamic State surrounded the Kurdish town of Kobani in northern Syria, along the Turkish border. To fend off the assault, the United States armed the region’s main Syrian Kurdish militia while bombing heavily from the air.

The strategy worked, and the United States found a new partner in Syria, the Kurdish militia known as the People’s Protection Units, or Y.P.G. The militia was a Syrian offshoot of the Kurdistan Workers’ Party, or P.K.K., which has long fought for Kurdish autonomy in Turkey.

Unlike Syria’s Arab rebels, the Kurds were happy to fight the Islamic State instead of the Syrian government. And as a secular movement, they raised no concerns that they might harbor sympathies with Islamist extremists.

With backing from the United States and its allies, the group pushed the jihadists from other parts of Syria and built ties with other militias. In 2015, under prompting from the United States, it rebranded itself as the Syrian Democratic Forces — a mix of Kurdish, Arab and other fighters.

In the process, Mazlum became essential to the United States.

“We tend to go to Mazlum for everything,” said one American official who has worked with the militia leader. But the partnership suffered a blow in December when President Trump said he was withdrawing the 2,000 American troops from eastern Syria.

Since then, American plans have changed repeatedly, most recently calling for a drawdown to 1,000 troops followed by a reassessment. Mazlum said he hoped the United States would remain to help take on the Islamic State fighters who have gone underground and to oversee a restructuring of the S.D.F. into an internal security force.