The deportation of three men from the UK to Nigeria on Tuesday night was halted by the high court because they may be able to provide evidence about the death of a man in a detention centre.

Oscar Okwurime died in Harmondsworth detention centre next to Heathrow airport last Thursday. In an order made in the high court on Tuesday preventing the three men flying, Mr Justice Butler said: “There is a serious issue that there should not be a removal of persons for whom there are grounds to believe that they may have material evidence to give in relation to the death of Oscar Okwurime.”

However, he refused to accede to the request of lawyers representing some of the detainees who were in detention with Okwurime to widen the order to others due to fly on Tuesday who may also have information about his death.

A second application to broaden the injunction to this bigger group by lawyers representing some of the detainees before Mr Justice Jacobs on Tuesday evening also failed. The lawyers are making an emergency out of hours application to the court of appeal.

The shadow chancellor, John McDonnell, has called for an independent public inquiry into the death of Okwurime at Harmondsworth which, together with the neighbouring Colnbrook site, is the biggest such detention centre in Europe.

McDonnell tweeted: “I am deeply saddened and extremely concerned at another death in Harmondsworth detention centre in my constituency. An independent public inquiry is now urgently needed into the fatalities, medical impacts and harm caused by the use of detention.”

Detainees say Okwurime was arrested last month when he arrived at Heathrow from Nigeria. They say he had claimed asylum on arrival. His former cellmate, also from Nigeria, was released from detention just hours before he died.

He told the Guardian: “I called Oscar after lock-up on the night that he died. I may have been the last person he spoke to before he died. He was hoping that like me, he too would be released from detention. When he arrived in Harmondsworth, his blood pressure was taken. The nurse told him it was very high and that he needed to relax.

“He kept trying to get an appointment with a doctor in the detention centre but I don’t think he succeeded. This is such a difficult situation. I’m heartbroken. He was such a lovely and intelligent guy.”

Detainees reported hearing Okwurime calling out for help on the night he died. “We are all locked in during the night,” said one. . “If we had not been locked in, I would have gone to his assistance when he cried out for help.”

After Okwurime’s death, a note was circulated to detainees from Mitie Care & Custody, which has a Home Office contract to run the centre. The centre manager, Paul Rennie, said his company had launched an internal investigation alongside other investigations.

He described it as a “very sad and tragic event”, adding: “Please be assured we are doing all we can to reduce the risk of such incidents happening again in the future.”

The Home Office said police, the coroner and the prisons and probation ombudsman were investigating Okwurime’s death.

Toufique Hossain and Jamie Bell of Duncan Lewis Solicitors, who brought Tuesday’s legal challenge, said: “The offer of condolences from the organisation in whose supposed ‘care’ a man died is void of any meaning. The Home Office is a removal machine that is now sweeping up potential key witnesses to its own neglect.”

Karen Doyle, of the Movement for Justice campaign group, said: “Fellow detainees responded to the horrendous discovery of Oscar’s death with a determination to expose the truth and stop a cover-up. Despite being incarcerated they got their voice out. They are the only voice Oscar has left. And until all of them are safe from removal the truth will only be partial and justice will be jeopardised. Mitie and the Home Office must jointly be held to account.”

A Home Office spokesperson previously told the Guardian: “Any death in detention is a tragic event and our thoughts and condolences are with the family and friends of Mr Okwurime. The welfare of all those in our care is of the utmost importance. All deaths in immigration detention are subject to investigation by the police, the coroner and the independent prisons and probation ombudsman.”