When the Civil War began the basic structure of the infantry was as follows:
I. 3 to 5 regiments formed a Brigade
A. Commanded by a Brigade General
II. 2 to 5 brigades made a division
A. Commanded by a Major General
III. 2 or more divisions made a Corps
A. Commanded by a Lt. General of Major General
IV. 2 or more Corps made an Army
A. Think Army of Northern Virginia (CSA) led by Robert E. Lee fighting the Army of the Potomac (USA) led by George Meade.
The numbers did not always work out perfectly, especially closer to the end of the war when units were not at full strength and other units were being pushed together out of necessity.