Islamist Turkish President Recep Tayyip Erdogan warned the United States in remarks Monday to stop “siding with terrorists” for Washington’s continued support of Syrian Kurdish groups instrumental to defeating the Islamic State.

Erdogan’s renewed accusations that, by working with the People’s Protection Units (YPG/YPJ) in Syria, American forces are also aiding the Kurdistan Workers’ Party (PKK) terrorist group, present the first major challenge from Ankara to the administration of President Joe Biden, who as vice president and presidential candidate made overtures to Kurdish communities. The remarks have prompted some in Erdogan’s Islamist Justice and Development Party (AKP) to accuse Biden of being secretly Kurdish and changing his name to hide his true ethnicity.

The Turkish government, a NATO ally, considers the YPG indistinguishable from the PKK. The PKK is a U.S.-designated terrorist group of Marxist inclination. The YPG is the militia protecting Rojava, or Syrian Kurdistan, and has enjoyed positive relations with the U.S. military for years. A YPG-led coalition known as the Syrian Democratic Forces (SDF) did much of the groundwork to liberate the “capital” of the Islamic State, Raqqa, from ISIS in 2017, with air support from Washington.

Following the fall of the Islamic State, Erdogan invaded northern Syria, allegedly to protect Turkey from PKK attacks. Turkish forces have also invaded northern Iraqi territories that form part of greater Kurdistan, though the Kurdistan Regional Government (KRG) of Iraq has long distanced itself from the PKK and typically enjoys friendly relations with Turkey. The invasion has displaced tens of thousands of people, according to the United Nations, and prompted accusations of ethnic cleansing from Kurdish groups.

Erdogan’s remarks on Monday were a response to Ankara revealing on Sunday that PKK terrorists had reportedly killed 13 Turkish hostages in Iraq. Erdogan expressed outrage at the U.S. State Department for condemning the attack. The United States, he said, was “obviously backing” the PKK, although it has officially designated it a terrorist organization for years.

“To continue our alliance globally and at NATO, then you must stop siding with terrorists,” Erdogan warned the Biden administration. “The blood of innocent people martyred in northern Iraq is on the hands of all defending, supporting and sympathizing with PKK terrorists.”

Turkey’s Anadolu news agency, a state media outlet, described those killed in Iraq only as Turkish “citizens,” implying they were not all members of the military or police force, though the region of Iraq where the incident occurred is part of Operation Claw-Eagle, Turkey’s formal name for its invasion of Iraq. Neither the governments of Iraq nor Syria support the presence of Turkish troops on their land and Kurdish representatives in both nations have also urged Turkey to withdraw.

The PKK disputed the claim that those killed were shot dead by members of the group. According to the Kurdish outlet Rudaw, the terrorist group issued a statement claiming the 13 individuals had been held hostage since 2015 and died after Turkish forces bombed a PKK target where they were being held, accusing Turkey of killing its own citizens. The PKK statement claimed none of those killed were civilians.

Turkish officials enacted mass arrests in the country on Monday against individuals allegedly tied to the PKK. Rudaw reported that at least 27 people are now in police custody, accused of stockpiling Molotov cocktails and other rudimentary weapons to attack police on Monday in observance of the anniversary of the arrest of the head of the PKK, Abdullah Ocalan, who remains in prison in Turkey currently.

A statement from the U.S. Department of State condemned the killings, apparently promoting Erdogan to attack Washington.

“The United States deplores the death of Turkish citizens […] We stand with our NATO Ally Turkey and extend our condolences to the families of those lost in the recent fighting,” the statement read. “If reports of the death of Turkish civilians at the hands of the PKK, a designated terrorist organization, are confirmed, we condemn this action in the strongest possible terms.”

Erdogan reportedly called the statement “a joke.”

Pro-Erdogan Turkish media, which represents most of the media landscape in Turkey after Erdogan shut down or purged dozens of outlets of their original staffs following a 2016 failed coup attempt against his presidency, rapidly embraced Erdogan’s attack on the United States. One of Turkey’s most excitable pro-Erdogan columnists, Ibrahim Karagül of the Islamist Yeni Safak newspaper, claimed the PKK was an arm of a greater global coalition led by the West to destroy the Turkish state in a column on Monday.

“The Kurdistan Workers’ Party (PKK) and other terrorist organizations are part of the West’s fight against Turkey. We need to forget the concept of ‘anti-terrorism.’ This concept no longer has a response in regional and global power showdowns,” Karagül wrote, without addressing the fact that the PKK is a designated terrorist organization in most of the West. “Once again, our citizens were martyred with weapons provided by the U.S., and the support of European countries. Our nation suffered another affliction with the internal and foreign attacks targeting Turkey.”

Karagül concluded with a call for the Turkish military to “purge” Syrian Kurdistan “before the U.S. and its components act again.”

Follow Frances Martel on Facebook and Twitter.