A Baton Rouge man serving a 20-year prison sentence for armed robbery tried to fake his way out of East Baton Rouge Parish Prison by pretending he was another inmate set to bail out of jail, parish sheriff’s deputies said.

But a deputy, suspecting something was wrong, stopped Brian P. White, 22, just as he had forged a signature on the appearance bond, deputies said.

Sometime before 8 p.m. Tuesday, White had answered to the name of the inmate who was bailing out of jail after a sheriff’s deputy called the inmate’s name, deputies said.

White stepped out of his cell and started signing an appearance bond. But the deputy became suspicious and started questioning him, deputies said.

White had finished filling out the appearance bond when the deputy figured out he wasn’t the right inmate, deputies said. White didn’t know the inmate’s date of birth.

White had forged the inmate’s name and signature on the appearance bond and put a false address and phone number on it, deputies said.

White, formerly of Madison Avenue, Baton Rouge, was booked Tuesday on counts of attempted simple escape, identity theft, forgery, attempting to commit a crime, obstruction of justice and injuring public records.

He was convicted of armed robbery in August 2015 but the jury deadlocked on manslaughter and other charges in a fatal crash stemming from a police chase that came eight hours after the robbery in January 2014. A judge ordered a mistrial on those charges.