The volume of the box is the product of its three dimensions, length, width, and height. The product of a number of "inches" and a "pure number" (3 has no units given) will not be "cubic inches."
_____
As it happens, the cube-shaped box with a volume of 27 cubic inches will have a height of 3 <em>inches</em> and a side area of 9 <em>square inches</em>. The edge length of the cube is 3 inches, not 9.