A Ghanian national in the country illegally who is charged with raping a woman in his Uber car before absconding to his native country was placed on an immigration detainer following his arrest, federal authorities said.

Frederick Q. Amfo, 30, who lived in Quincy, was arraigned Friday for the alleged rape of Emily Murray during the early morning hours of April 8.

Amfo was released from custody after posting $10,000 bail. Investigators suspect he was able to fly home to Ghana because of an error in how the court handled his passport.

U.S. Immigration and Customs Enforcement personnel said the mistake should have never happened and they’re blaming officials at Quincy District Court.

“Following his arrest on rape charges, ICE issued an immigration detainer to the Weymouth Police Department for Frederick Amfo. … That detainer should have followed the alien as he transferred from the Quincy Court House. The court chose not to forward the detainer to Norfolk County, allowing for his subsequent release on bail from custody,” ICE spokesman John Mohan said in a statement.

“This case highlights the potential dangers of policies that prohibit cooperation with ICE,” he added. “ICE detainers serve as a legally authorized request, upon which a law enforcement agency may rely, to continue to maintain custody of an alien for up to 48 hours so that ICE may assume custody for removal purposes.”

However, a spokeswoman for the state Trial Court said federal officials are wrong.

“The Quincy District Court did not receive an immigration detainer document for defendant Frederick Amfo. Consistent with court practice, had the Quincy District Court received a copy of an immigration detainer it would have forwarded that detainer to the House of Correction,” the spokeswoman said.

Murray, 30, of Weymouth said she’s tired of the blame game.

“It’s just a bunch of finger-pointing. At least we’re narrowing down where stuff happened. … But something has to be done where it’s not a case of human error anymore,” she said. Her emotional “wound is still very much open and raw,” Murray said.

The Norfolk District Attorney’s Office also said it never received information about Amfo’s immigration detainer. Court records state Amfo had 24 hours to surrender his passport after posting bail — a procedure that is now changed. Anyone ordered to surrender a passport must do so before being bailed.

The U.S. has an existing extradition treaty with Ghana and as part of the decades-old agreement, the countries will surrender a person for trial or punishment for a series of different crimes. Rape is one of the crimes under the accord that will trigger extradition, the agreement states.

A State Department official said in an email that its policy is to “not comment on specific extradition requests” and referred comment to the Department of Justice. A DOJ spokeswoman said the department does not discuss extradition requests.

Amfo’s case is the latest evidence of growing tension between state and federal immigration authorities on the heels of a Supreme Judicial Court decision last year. The SJC declared that state officials don’t have the power to detain someone based on a request from ICE alone.