According to one book I've read on the development and continuity of Orthodox worship, the growth of the iconostasis was gradual. It began as railing to screen the altar that grew to a frame that held the curtain. That led to "doors" By the 4th and 5th centuries areas near the posts were enlarged to receive icons. As more icons were hung more solid area was added to support them until the whole thing had grown into an icon covered partition between the nave and the altar. By the 15th century in Russia it had become an icon wall.
The rood screen of English churches is the survival of the basic frame stage of the iconostasis. The curtains were removed around the time of the Reformation, I think.
The reason for both the curtain and the iconostasis developed as a response to the presence of those among the people who were either not Christians, still Catecumens, or Baptized but in a penitential status that proscribed communion. In the very early days the liturgy of the Word and the Divine Liturgy were separated services. Only baptized Christians in good standing were permitted at the liturgy (not a spectator affair). Since the holy things were for the holy and they were only meant to be seen and partaken of by those spiritually ready for communion, the partition protected the holy things from the gaze of the profane and spiritually lax, though the mystery going on within the altar was made present in the icons of the iconostas so that hearts might still ascend via the duller senses of the body through contemplation of the images.