A Russian man accused of fighting alongside Taliban insurgents in Afghanistan and leading an attack against coalition forces in 2009 pleaded not guilty Friday to terrorism charges in U.S. District Court.

During a short hearing at the courthouse in downtown Richmond, the judge also ordered Irek Ilgiz Hamidullan to remain in U.S. custody as he awaits trial.

Hamidullan, who was indicted last month, was captured after the assault and secretly held at a detention facility near Bagram air base in Afghanistan, where FBI agents began interviewing him to try to build a criminal case.

He was flown back to face trial in the Eastern District of Virginia this week, marking the first time a foreign combatant captured on the battlefield in Afghanistan has been brought to the United States to be prosecuted.

Among the charges are conspiring to murder a U.S. national and use of a weapon of mass destruction. The weapon charge carries a possible death sentence, but prosecutors said they won’t seek execution.

If convicted, Hamidullan, who is believed to be about 55, could spend the rest of his life behind bars.

Hamidullan, who spoke a little English to Judge Henry Hudson, said he understood the charges against him. At times, though, he used an Arabic-speaking interpreter. He made one request: that the court spell his last name differently. The judge obliged, saying he would add it as an alias to the indictment.

Hamidullan appeared relaxed and smiled a few times. He was shackled, but security was relatively light. There were several U.S. marshals in the courtroom but no heavily armed guards or other obvious security precautions.

According to the indictment, Hamidullan served in the Soviet military in the 1980s as an officer and tank commander and later joined the Taliban. He was trained in the use of heavy weapons such as antiaircraft weapons and portable rockets.

The indictment said that during the attack, Hamidullan “directed the positioning of the three groups and the weapons they carried, which included AK-47 machine guns, hand grenades, a DsHK antiaircraft machine gun, an 82 millimeter recoilless rifle, a BM 1 portable rocket, rocket-propelled grenades, and additional weapons.”

The Obama administration had struggled with what to do with Hamidullan, debating whether to prosecute him in a civilian or military court as combat operations come to an end in Afghanistan. U.S officials have said the Russian government has shown little interest in Hamidullan.

A representative of the Russian government attended the hearing but declined to comment, referring questions to the Russian Embassy in Washington.

The judge set the trial for April. The prosecution said the trial was expected to take three to five days.