Iranian-backed militias in Iraq have warned “all retaliation options are on the table” and they will “send American soldiers back in coffins” if US citizens do not pressure their government to withdraw troops from the country.

The comments came as Iraq’s prime minister told the US ambassador to Baghdad that Washington must cooperate to prevent “an open war” with Iran and pull out its forces.

Speaking to The Independent, factions within the Iraqi Popular Mobilisation Forces (PMF), said they had “no red lines hindering their revenge” for the Friday drone strike on Baghdad Airport which killed Iranian general Qassem Soleimani and Abu Mahdi al-Muhandis, the PMF’s chief.

They threatened attacks against US military interests and servicemen in Iraq but said the net may widen to civilians if the nation re-elected Donald Trump, therefore, endorsing “his crimes”.

On Monday Iran’s Supreme Leader Ayatollah Ali Khamenei led funeral prayers in Tehran over the remains of Soleimani, who headed up the Quds Force, the foreign military arm of Iran’s elite Revolutionary Guards that worked closely with the PMF.

US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Show all 35 1 /35 US airstrike kills Iran's Qassem Soleimani: Fallout in pictures US airstrike kills Iran's Qassem Soleimani: Fallout in pictures This photo released by the Iraqi Prime Minister Press Office shows a burning vehicle at the Baghdad International Airport following an airstrike in Baghdad, Iraq, early Friday 3 January AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures The wreckage of the car in which general Soleimani was travelling when a targeted US airstrike struck outside Baghdad International Airport on 3 January Ahmad Al Mukhtar via Reuters US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Demonstrators burn the US and British flags during a protest in Tehran after general Soleimani was killed in a targeted airstrike by American forces Reuters US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A burning vehicle at the Baghdad International Airport following an airstrike. The Pentagon said Thursday that the US military has killed general Qassem Soleimani, the head of Iran's elite Quds Force, at the direction of Donald Trump AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Protesters burn Israeli and US flags as thousands of Iranians take to the streets to mourn the death of general Soleimani at the hands of America EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Supporters of Donald Trump pray at an 'Evangelicals for Trump' campaign event held on the day following the killing of general Soleimani. At the event, the president praised the "flawless strike that eliminated the terrorist ringleader" AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A huge procession of mourners gather in Baghdad for the funeral of general Soleimani on 4 January AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Thousands of Iranians take to the streets to mourn the death of Soleimani during an anti-US demonstration to condemn the killing of Soleimani, after Friday prayers in Tehran, Iran EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iraqis perform a mourning prayer for slain major general Qasem Soleimani of the Iranian Revolutionary Guards at the Great Mosque of Kufa AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A billboard reading 'Death to America and Israel', installed by Iran-backed shiite armed groups at a street in Jadriyah district in Baghdad, Iraq EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A handout picture provided by the office of Iran's supreme leader Ayatollah Ali Khamenei shows him visiting the family of Soleiman KHAMENEI.IR/AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Thousands of Iranians take to the streets in Tehran EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Pakistani Shiite Muslims burn a mock of a US flag as they hold pictures of General Qasem Soleimani during a protest against the USA, outside the US Consulate in Lahore, Pakistan EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iran's Ambassador to Lebanon Mohammed Jalal Feiruznia, looks to a portrait of Soleimani, as he receives condolences at the Iranian embassy, in Beirut, Lebanon AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures People make their way on the street while a screen on the wall of a cinema shows a portrait Soleimani in Tehran AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Aziz Asmar, one of two Syrian painters who completed a mural following the killing of Iranian Revolutionary Guards commander Qasem Soleimani poses next to his creation in the rebel-held Syrian town of Dana in the northwestern province of Idlib AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A demonstration in Tehran AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures An anti-US demonstration to condemn the killing of Soleimani, after Friday prayers in Tehran EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Mujtaba al-Husseini, the representative of Iran's supreme leader Ayatollah Ali Khamenei, delivers a speech in the holy shrine city of Najaf AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Pakistani Shiite Muslims burn a mock of a US and Israeli flags as they hold pictures of General Qasem Soleimani during a protest against the USA, outside the US Consulate in Lahore, Pakistan EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Protesters demonstrate in Tehran AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Pakistani Shi'ite Muslims hold pictures of General Qasem Soleimani during a protest against the USA, in Peshawar, Pakistan EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Protesters, holding a photograph of the leader of the People's Mujahedin of Iran Massoud Rajavi, outside Downing Street in London PA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Protesters burn a US flag in Tehran AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A Syrian man offers sweets to children to mark the killing AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iranian worshippers attend a mourning prayer for Soleimani in Iran's capital Tehran AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Kashmiri Shiite Muslims shout anti American and anti Israel slogans during a protest AP US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iranian worshipers chant slogans during Friday prayers Reuters US airstrike kills Iran's Qassem Soleimani: Fallout in pictures A protest against the USA, in Islamabad, Pakistan EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iranians burn a US flag in Tehran EPA US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Supporters of the National Council of Resistance of Iran in Germany (NWRI) protest outside Iran's embassy in Berlin, Germany Reuters US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Supporters of the National Council of Resistance of Iran in Germany (NWRI) protest outside Iran's embassy in Berlin Reuters US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iranian worshippers in Tehran AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Vehicles of the United Nations Interim Forces in Lebanon (UNIFIL) patrol a road in the southern Lebanese town of Kfar Kila near the border with Israel. Following morning's killing of Major General Qasem Soleimani, Lebanon's Iran-backed Hezbollah movement called for the missile strike by Israel's closest ally, to be avenged AFP via Getty US airstrike kills Iran's Qassem Soleimani: Fallout in pictures Iranian women take to the streets in Tehran EPA

Iranian state TV claimed millions had poured onto the streets to bid farewell to the feared commander. The scale of the crowds shown on television appeared to be the biggest since the 1989 funeral of the founder of the Islamic Republic, Ayatollah Ruhollah Khomeini.

“Our message to the American people is you have to pressure Trump’s government to withdraw their troops from Iraq before we send your soldiers back in coffins,” said Jawad Al Telbawi, a commander and spokesman for a faction within the Iran-supported PMF.

“All retaliation options are on the table. After the crime committed by Trump’s administration, our revenge will be the size of our doctrine and no red lines shall hinder our revenge.”

Calling the American president a “fool and a blackmailer” he added that if the US people re-elected Mr Trump in the 2020 elections, the PMF and its affiliates will scale up the violence.

“If the American people re-elect Trump to the US presidency, this would mean they support his crimes. This may change our position towards the American people. All American interests in the region will be at risk.”

Iraq’s caretaker prime minister Adel Abdul-Mahdi met the US ambassador Mathew Tueller on Monday to urge cooperation saying it was key to prevent “sliding towards an open war” with Tehran.

He told the diplomat the US must also work with Iraq to bring about the withdrawal of American troops from Iraqi soil.

Tensions in Iraq and the wider Middle East reached boiling point this week, after a US drone strike in Baghdad killed Soleimani, Abu Mahdi al-Muhandis and several other officials.

Soleimani, 62, who oversaw the training and financing of Iran’s feared proxy groups like the PMF in Iraq and the Lebanese Military group Hezbollah, was responsible for the deaths of hundreds of Americans, as well as overseeing the killing of civilians and sieges in places like Syria.

But to his supporters in the region, he was a key figurehead in the battle against western imperialism. His death has only galvanised that image across the region.

In Iraq, the PMF’s forces called the US army “criminals”.

“We shall convulse the ground underneath the American army’s feet in Iraq. These are not slogans, rather truths in which we believe,” Mr Telbawi added.

The assassination also angered Iraq who saw the strike as a massive violation of the country’s sovereignty. Iraq’s parliament voted on Sunday to expel US and foreign troops in the wake of the killing.

Baghdad has for years worked to balance its alliances with both Washington and Tehran: some 5,000 US military personnel are believed to be in Iraq to help fight Isis militants and train Iraqi forces.

Furious, Mr Trump threatened to impose sanctions on Baghdad if they followed through with expelling US troops. He also demanded billions of dollars in financial compensation for US military investments in Iraq over the years.

He later threatened to target 52 sites in Iran, including areas of cultural importance, which if carried out would likely be a war crime, according to legal experts.

On Monday night an apparently leaked letter suggested that the US military was pulling out of Iraq, but Mark Esper, the defence secretary, later said this was not the case.

Iranian President Hassan Rouhani responded by saying the US president should “never threaten the Iranian nation”.

America’s western allies have rushed to try to pull back the US and Iran from the brink of war.

Dominic Raab, who spoke to Iran’s foreign minister Mohammad Jawad Zarif on Monday, urged all sides to find a diplomatic solution to tensions.

“The key message that we have got to all of our European and American partners but critically also to the Iranians, to the Iraqis and all of those affected in the region is the importance of defusing the tensions, to de-escalate ... and the importance of finding a diplomatic way through,” Mr Raab said.

Jens Stoltenberg, Nato’s secretary general, also called for restraint during emergency talks between Nato ambassadors in Brussels on Monday, where he said: “A new conflict would be in no one’s interest.”

Members of the Hashed al-Shaabi, or Popular Mobilisation Forces (PMF), paramilitaries stand guard during a funerary procession for Wissam Alyawi, a leading commander of the Asaib Ahl Al-Haq faction that is part of the PMF, in the Iraqi capital Baghdad on October 26, 2019 (Photo by AHMAD AL-RUBAYE/AFP via Getty Images)

Ursula von der Leyen, head of the European Commission, meanwhile focused on the 2015 nuclear deal with Iran, brokered with the US, UK, France, China, Russia and Germany, that aimed to prevent Tehran from building an atomic weapon.

After Soleimani’s killing Tehran said it would no longer abide by any limits of an international nuclear deal including restrictions on the enrichment of uranium, or research and development, dealing a devastating blow to the deal.

“We have to convince Iran that it’s also in its own interest,” she said.

France’s foreign minister Jean-Yves Le Drian said Iran could now enrich uranium without any constraints and so European powers would consider launching the dispute mechanism for the deal in the coming days.

In Iran the country’s Supreme Leader Ayatollah Ali Khamenei, who had a close relationship with Soleimani, presided over the main funerary prayers in Tehran – where he wept as he prayed over the commander’s casket.

Over the last few days, mass funerary processions have taken place across the country, which up until recently had been gripped by nationwide anti-government protests during which more than 300 people were reportedly killed.

The commander’s assassination appears to have temporarily silenced that anger and instead has seen politicians and leaders across the Islamic Republic’s political spectrum take part in the mourning.

Soleimani’s successor, Esmail Qaani, stood near Khamenei’s side, as did Iranian president Hassan Rouhani and other top leaders in the Islamic Republic.

The leader of the Palestinian militant group Hamas which governs the blockaded Gaza Strip was also in attendance, despite the fact that Egypt has only granted him permission once to travel in December on the condition he did not visit Iran.

Soleimani’s daughter Zeinab also spoke reiterating that her father’s killing will only “resurrect” the cause.

“Crazy Trump, don’t think that everything is over with my father’s martyrdom,” she said.

Mr Qaani, the new head of the Quds force, made his own threat in an interview with Iranian state television also aired on Monday.