Man needs to be sufficiently developed in order to deal with the more profound issues of life.
For the simple matters, he could have remained in Eden, but to deal with the world outside the Garden, in order to complete the world, so to speak, man had to grow up.
Some Sages say this is the meaning of the phrase in Genesis at the end of the account of the Creation: "which God created, to do" (Genesis 2:3).
That is, God creates a world that still has all sorts of things in it that are incomplete, and man's task is to complete them.
How can man complete creation so long as he remains in the Garden of Eden?
–Rabbi Adin Steinsaltz
From "The Two Ways of Tikun," In the Beginning by Rabbi Adin Steinsaltz