Yes, the beam is steered by adjusting the relative phases of the signals to/from the elements the spacing between the elements are critical to which direction the beam points for a given set of phase relationships.
The most basic restriction is usually the avoidance of grating lobes when you scan by changing the relative phasings of the rows. You work this out from the range of scan angles you need. Half-wave spacing is as large as you can go and avoid grating lobes whilst maintaining full scanning range.
Knowing nothing about your problem, it's impossible to give detailed advice. Being homework, you learn by trying things out.