International medical charity Doctors Without Borders (MSF) said Sunday it has withdrawn staff from the embattled Afghan city of Kunduz, a day after an apparent United States bombing raid on its hospital that the United Nations said could amount to a war crime.

MSF also called for an independent international investigation of the air strike.

MSF said on Sunday that 22 people were killed, including 12 staffers and 10 patients. The group added that some victims burned to death in their beds as the bombardment continued for more than an hour, even after U.S. and Afghan authorities were informed the hospital had been hit.

It is the only medical facility in the northeastern region of Afghanistan that can deal with major war injuries. Its closure, even temporarily, could have a devastating impact on local civilians.

"The MSF hospital is not functional anymore. All critical patients have been referred to other health facilities and no MSF staff are working in our hospital," Kate Stegeman, a spokeswoman for the charity, told Agence France-Presse. "I can't confirm at this stage whether our Kunduz trauma center will reopen or not."

The air raid came five days after Taliban fighters seized control of the strategic northern city of Kunduz, in their most spectacular victory since being toppled from power by a U.S.-led coalition in 2001.

The medical charity condemned the bombings as "abhorrent and a grave violation of international law," demanding answers from U.S.-led NATO forces in Afghanistan.

U.S. Defense Secretary Ash Carter promised a full investigation into whether the American military was connected to the destruction of the hospital but MSF General Director Christopher Stokes said in a statement that that "would be wholly insufficient."

"Under the clear presumption that a war crime has been committed, MSF demands that a full and transparent investigation into the event be conducted by an independent international body," Stokes said.

It said Afghan and coalition troops were fully aware of the exact location of the hospital, having been given GPS coordinates of a facility that had been providing care for four years.

It added that despite frantic calls to military officials in Kabul and Washington, the main building housing the intensive care unit and emergency rooms was "repeatedly, very precisely" hit almost every 15 minutes for more than an hour.

Afghan officials said helicopter gunships returned fire from Taliban fighters who were hiding in the facility.

Stegeman said there were no insurgents in the facility at the time of the bombing.

MSF said some 105 patients and their caregivers, as well as more than 80 international and local MSF staff, were in the hospital at the time of the bombing.

"The bombs hit and then we heard the plane circle round," said Heman Nagarathnam, MSF's head of programs in northern Afghanistan. "There was a pause, and then more bombs hit. Those people that could had moved quickly to the building’s two bunkers to seek safety. But patients who were unable to escape burned to death as they lay in their beds."

Twelve staff members and at least seven patients, among them three children, were killed, while 37 people were injured.

On Saturday President Barack Obama offered his "deepest condolences" for what he called a "tragic incident."

"The Department of Defense has launched a full investigation, and we will await the results of that inquiry before making a definitive judgment as to the circumstances of this tragedy," Obama said.

Afghan President Ashraf Ghani has said a joint investigation is underway with U.S. Forces.

NATO earlier conceded U.S. forces may have been behind the bombing, after its forces launched a strike that they said was intended to target militants.

"The strike may have resulted in collateral damage to a nearby medical facility. This incident is under investigation," a statement said.

The incident has renewed concerns about the use of U.S. air strikes in Afghanistan, a deeply contentious issue in the 14-year campaign against Taliban insurgents.

U.N. rights chief Zeid Ra'ad Al Hussein called for a full and transparent probe, noting: "An air strike on a hospital may amount to a war crime. This event is utterly tragic, inexcusable and possibly even criminal.”

MSF's withdrawal comes as Kunduz grapples with a humanitarian crisis, with thousands of civilians caught in the crossfire between government forces and insurgents. At least 60 people are known to have died and 400 to have been wounded in the past week's fighting.

"Such attacks against health workers and facilities undermine the capacity of humanitarian organizations to assist the Afghan people at a time when they most urgently need it," the International Committee of the Red Cross said.

The deputy head of the Afghan National Disaster Management Authority, Aslam Sayas, said he was aware of the growing needs of people trapped inside the city. "We are waiting for the security situation to improve to give us an opportunity to reach those needy people," he said.

Saad Mukhar, the Kunduz provincial public health director, estimates that more than 70 people have been killed and more than 500 wounded in the city since the fighting began.

"I'm afraid that if this situation continues, we will not be able to help our patients because right now we are facing a serious, drastic shortage of medicine," he said.

Correction: This story deletes a reference to weaponry in the hospital windows as seen in AP video after further review of the images cast doubt on whether they were rifles and a machine gun or simply charred debris from the bombing.

Al Jazeera and wire services