How to create a cube from two united planes?
One of many ways to achieve an extrusion-like result if one face is already in place: 


select the two open edges in edge-selection mode
&nbsp;

&nbsp;
Shift + S: snap 'Cursor to Selected'
&nbsp;

&nbsp;
set pivot mode to '3D Cursor'
&nbsp;

&nbsp;
select 'hinge' edge at the bottom
&nbsp;

&nbsp;
Shift + D to duplicate, S, -, 1, Enter to mirror around 3D Cursor
&nbsp;

&nbsp;
Fill the result by selecting pairs of edges and pressing F
&nbsp;