President Trump on Monday suggested that Kurds are allowing Islamic State militants escape from prisons to lure the US back into Syria — a day after the administration ordered remaining troops from the country amid intensifying fighting and a mass breakout of the terror group’s followers.

Trump was responding to remarks from “Fox & Friends” host Brian Kilmeade who said the president “must realize he made a huge mistake” by withdrawing US troops from Syria, a move that he said brought “bipartisan outrage.”

“Brian Kilmeade over at @foxandfriends got it all wrong. We are not going into another war between people who have been fighting with each other for 200 years,” Trump wrote on Twitter. “Europe had a chance to get their ISIS prisoners, but didn’t want the cost. ‘Let the USA pay,’ they said.”

In another post he suggested the Kurds, who guard the ISIS fighters in prisons in northern Syria, may be using them to influence US policy.

“Kurds may be releasing some to get us involved. Easily recaptured by Turkey or European Nations from where many came, but they should move quickly,” the president said. “Big sanctions on Turkey coming! Do people really think we should go to war with NATO Member Turkey? Never ending wars will end!”

Defense Secretary Mark Esper announced on Sunday that the US would pull its remaining forces from Syria so they wouldn’t be caught up in the fighting between Turkish and Kurdish troops.

About 950 supporters of ISIS — including wives, widows and children of the terror group’s fighters — fled a Kurdish-run detention camp in Ein Eissa, about 20 miles south of the Turkey border, on Sunday.

The Trump administration announced last week it had authorized the Treasury Department to slap sanctions on Turkey for invading Syria.

Asked Sunday why there was a delay in imposing the penalties on Turkey, Treasury Secretary Steven Mnuchin told ABC’s “This Week” that “it is a complicated, developing situation involving a NATO ally.”

Trump has been criticized for giving Turkish President Recep Tayyip Erdogan the go-ahead earlier this month to invade Syria because the move left the Kurds, who fought alongside the US against ISIS, at the mercy of Turkish forces.

Ankara views the Kurdish fighters as a terror group linked to an insurgent group fighting the Erdogan government inside Turkey.