PARIS (Reuters) - French President Emmanuel Macron warned Turkey that its operation against Kurdish militias in northern Syria should not become an excuse to invade the country and said he wanted Ankara to coordinate its action with its allies.

Turkey last week launched an air and ground offensive in northwest Syria, targeting the Kurdish YPG militia in the Afrin region. That has opened a new front in the seven-year-old civil war and strained ties with Turkey’s NATO allies.

“If it turns out that this operation takes a turn other than to fight a potential terrorist threat to the Turkish border and becomes an invasion operation, (then) this becomes a real problem for us,” Macon said in an interview with Le Figaro newspaper published on Wednesday.

Turkey considers the YPG a terrorist organization and an extension of the outlawed Kurdistan Workers Party (PKK), which has waged a three-decade-long insurgency in Turkey’s largely Kurdish southeast.

Turkish Prime Minister Binali Yildirim defended the operation saying it was solely aimed at securing his country’s security and protecting Arabs, Kurds and Turkmens from “terrorist organizations.”

“If France is interpreting this issue as such (invasion operation), we need to assess what they have done in Syria accordingly,” Yildirum said at a news conference alongside Lebanese Prime Minister Saad al-Hariri in Ankara.

“This is a crooked idea from the start. The whole world knows that Turkey is not acting with an invasive mind. They should know it.”

The United States and France have armed and trained YPG-led militia in the fight against Islamic State in Syria.

Macron said he would bring the issue up again with Turkish President Tayyip Erdogan and that the nature of the operation meant there should be discussions between Europeans, but also more widely among allies.