This section is from the book "The National Capitol. Its Architecture Art And History", by George C. Hazelton, Jr. Also available from Amazon: The National Capitol Its Architecture Art and History.
During the early part of the war, when Congress was not in session, the Capitol was a hospital for soldiers. The committee rooms were appropriated by the doctors and nurses, and each legislative chamber was turned into a general ward for the wounded, the cloak rooms and lobbies being reserved, for the most part, for the officers. At this time, huge bakeries were built in the cellarage back of the old sodded terrace ; and each morning army wagons might have been seen about the Capitol loading with loaves of bread to supply the forts, hospitals and encampments in the neighborhood. On July 11, 1862, an appropriation of $8,000 was made to remove these army bakeries and repair the damage which they had done.
The Capitol has never been regularly used as a prison; but occasionally men have been imprisoned in one of the basement rooms for contempt in refusing to answer questions put to them by committees who were making investigations in accordance with some act of Congress.