GENEVA (Reuters) - The International Committee of the Red Cross said on Thursday it had access to more than 1,300 foreign wives and children of suspected Islamic State militants following concerns expressed for the safety of the families held by Iraqi forces near Mosul.

The neutral aid agency called on all sides in the wars in Iraq and Syria to treat detainees in line with international law that prohibits torture or executions and enshrines the right to a fair trial.

More than 300 of the detained foreign families in Iraq came from Turkey, many others from former Soviet states, such as Tajikistan, Azerbaijan and Russia, according to preliminary figures from the Iraqi army.

“Currently we visit and provide humanitarian assistance to some 1,300 women and children of several dozen nationalities who are detained in Iraq near Mosul,” Patrick Hamilton, ICRC deputy director for the Middle East and North Africa, told a news briefing.

Last month, foreign aid agencies in Iraq said they were “gravely concerned” about the fate of the families. The women and children have been in Iraqi custody since August 30 following the fall of the city of Tal Afar.

It is the largest group of foreigners linked to Islamic State to be held by Iraqi forces since they began driving the militants from Mosul and other areas in northern Iraq last year.

The ICRC denounced some authorities and militias in the Iraq and Syria wars against Islamic State who have vowed to “annihiliate” the enemy, but declined to name names.

Such “dehumanisation” of the enemy could lead to unlawful torture or executions, Hamilton warned. “Talk of annihilation or extermination contributes to perpetuating the problem rather than solving it.”

International humanitarian law protects civilians and former combatants, he said.

The ICRC has a “good level of dialogue” with Iraqi authorities and has visited detention facilities in Iraq holding 44,000 people so far this year, Hamilton said.

Thousands of foreigners have been fighting for Islamic State in Iraq and Syria and an unknown number of them are now detained. Hamilton said the ICRC was already in talks about potential repatriation of foreign fighters.

“We are ready to play the role of a neutral intermediary to assist these states in carrying out that, the return of their individual citizens,” he said.

“Indeed we have been in dialogue with a number of different states and the Iraqi authorities in relation to this over recent weeks, he said.

Hamilton, asked about media reports of executions by U.S.-backed Syrian Democratic Forces (SDF) following the fall of the jihadist capital in Raqqa, Syria, said that an ICRC team had been in the “chaotic” northeastern city last week.

“No, we frankly don’t have first-hand information in regards to extrajudicial killings or any such like ... clearly we remain concerned in the aftermath of Raqqa as we do after Mosul, Hawija, Tal Afar and so forth,” he said.