Very large antennas are a key infrastructure for advanced space systems, but their size is limited by the size of the launching rocket's nose-fairing. This paper proposes an innovative phased-array antenna with foldable panels that overcomes this limitation through a combination of mechanical engineering and electrical engineering design. The antenna includes steps between the panels in contrast to traditional flat antenna designs, so as to fold panels of finite thickness without mechanical interference using ordinary, simple hinges (which are very reliable). As a result, excellent deployment efficiency and two-dimensional deployment have been achieved. However, the mechanical steps need to be compensated electronically in order to preserve the radiated beam characteristics, so the excitation phase of each radiator on the panels is precisely adjusted depending on the step size, radiation frequency and desired beam direction. The feasibility of both the deployment and phase-compensation methods was verified by both simulation and experiment, using a deployable mechanical model and an electrical model. Moreover, this technique is suitable for scaling up to very large antennas.