In the Washington
Post Times, Martha M. Boltz tells the tale of two Virginia cousins who left the farm when their uncle left them alone on the farm. Apparently they were a bit angry when their uncle joined the Yankees and they went off to join the Confederate Cavalry. They cut their hair, bound their breasts, affected deeper voices and a manly walk. Which seemed to have worked as one was promoted to Sergeant and the other to Corporal until their secret was uncovered.
As many girls similar serving had done, they told their secret to their captain, who kept it for them until his capture in 1864. It was [his successor] who gave the information to Gen. [Jubal] Early.
During their time with the troops, Mary was promoted to Sergeant and Mollie to Corporal. This did not matter to Early when he learned their true gender, and they were falsely accused of being “camp followers” or prostitutes and were put in prison.
But you should read the whole story.