Based on the statements of fellow soldiers he should be brought before a military magistrate on the desertion charge, and be remanded to the brig.
It’s called the stockade in the Army, brig is what the Naval services call it.