Some people ask why God didn’t begin at the end. Begin with the goal. The question is ambiguous.
1. Technically, “heaven” is the intermediate state, a disembodied, postmortem state between death and the general resurrection. So is the question why didn’t God create us after we died? But of course, God can’t create us after we die, inasmuch as we must already exist in order to die.
2. Is the question why didn’t God created us in a disembodied state? But that’s not an ideal condition. There are many benefits to embodied experience.
In that respect, the question suffers from popular confusion by theologically illiterate people who think heaven is the ultimate goal of human existence. You die, go to heaven, and live there forever. But that’s not Christian eschatology.
3. Is “heaven” being used as a synonym for the final (earthly) state, i.e. the new Eden/new Jerusalem? But God already created Adam and Eve in an Edenic earthly state. They fell.
4. Perhaps the question is why didn’t God create us perfect? Skip the journey and cut straight to the destination.
i) If so, that assumes the process is dispensable. And the end-result is achievable without experience. But is that realistic? Take forgiveness. You can’t experience forgiveness without prior wrongdoing. The sense of guilt, gratitude, and relief. So that condition can’t be directly created. It’s a nested effect, internally related to something prior. An intervening history is necessary prerequisite.
ii) In addition, creating everyone sinless and impeccable would preempt the lives of many people whose existence is contingent on a fallen world. They are products of chains of events involving sinful agents.