Turkey has warned Greece to refrain from “provocations” after a Greek flag was hoisted on a disputed, uninhabited islet in the Aegean Sea off the Turkish coast.

Prime minister Binali Yildirim told reporters that Turkish coast guards had removed the flag from the island off the coast of the Aegean resort of Didim.

Mr Yildirim said the incident was similar to one in 1996 when the two Nato allies went to war over uninhabited islets – known as Imia in Greek and Kardak in Turkish – which both Turkey and Greece claim.

“Our advice to Greece would be to stay away from provocations and agitations,” Mr Yildirim said, adding that Turkey was “determined to give the necessary response” to such acts.

Despite two decades of efforts to improve relations, Greece and Turkey have seen a spike in tensions in recent weeks over disputed Aegean boundaries and oil-and-gas drilling rights off the divided island of Cyprus.

Asked about the incident during a joint news conference with visiting the Nato chief, Turkish foreign minister Mevlut Cavusoglu accused Greece’s defence minister, Panos Kammenos – the outspoken leader of Greece’s nationalist party – of raising tensions in the Aegean Sea.

“His brattiness shouldn’t reach a level where it’ll damage relations between the two countries,” Mr Cavusoglu said.

In Athens, Greek government spokesman Dimitris Tzannakopoulos said the government had no knowledge of the incident and described the remarks by Mr Yildirim as “provocative and reprehensible”.

“I think Mr Yildirim should be more careful,” Mr Tzannakopoulos said.

“We call on Turkey to return to a path of respect for international law … They should take an initiative to de-escalate the tension.”