I see how a rectangular prism is made up of two squares and four rectangles.
Each square is isomorphic to $D_4$. Isn't a rectangle isomorphic to $D_2$ because there are two rotations (0 degrees and 90 degrees) and two reflections (horizontal and vertical axis)?
Also, since there are two squares and four rectangles, do we have to use this fact anywhere?