MANILA (Reuters) - Philippine President Rodrigo Duterte said on Wednesday he ordered the investigation into a 71-year-old Australian nun for “disorderly conduct”, justifying it as a legal move against “undesirable” foreigners.

Philippine President Rodrigo Duterte addresses an event with Filipino community in Hong Kong, China April 12, 2018. REUTERS/Bobby Yip

Sister Patricia Fox, a coordinator of a Philippine congregation of Catholic nuns called Notre Dame de Sion, was taken from her house this week and detained at the immigration bureau in Manila for almost 24 hours.

She was released on Tuesday pending further investigation.

Fox had taken part in rallies seeking the release of political prisoners and urging Philippine authorities to respect human rights, but she denied she was engaged in politicking.

“I ordered her to be investigated, not deported at once, not arrested, but to invite her to an investigation for a disorderly conduct,” Duterte said during the change of command ceremony of the Armed Forces of the Philippines.

Presidential spokesman Harry Roque said there was “probably” a need to apologize for the detention of Fox because she was not engaged in any political activity when she was taken from her home by immigration authorities.

“Perhaps an apology was in order. Clearly there was a mistake,” he said early on Thursday in an interview with ANC news channel.

Roque said Duterte had to clarify his order and had taken full responsibility for the incident.

“It’s a violation of sovereignty,” Duterte said, accusing Fox of badmouthing his administration. “You do not have that right to criticize us. Do not insult my country.

“We never did that to Australia. We never did that to (a) European country. Why don’t you criticize your own government, the way you handle the refugees, hungry and dying and you turn them back to the open sea,” he said.

The United Nations has called on Australia to take responsibility for around 800 refugees and asylum seekers stranded in a detention center on Papua New Guinea where it said many lack medical and mental health care.

Australia, which controversially holds asylum-seekers in offshore camps, has said the center on the island is adequate and that the Papua New Guinea government is responsible for running it.