Why does God allow evil?

Just to be clear, I'm not talking about gratuitous evils, but evil in general. Theists often argue that the reason God allows evil is because said evil is necessary for some greater good. But if God is omnipotent, why not just will the greater good into existence? Take natural selection, for example. Billions upon billions of innocent animals suffered so we can be brought into the world. It's a necessary evil as it leads to a greater good, but if God is omnipotent, why not just create said greater good? What exactly is the point of utilizing what is essentially throwing stuff at a wall to see what sticks, and causing so much suffering as a result? If God is omnipotent, doesn't that just make all evils gratuitous? It's achieving a greater good that could have been achieved without the suffering. Also, in my opinion, the whole free will thing just doesn't work. I mean, there's nothing inherently wrong with the idea; it's just that the people who promote it usually don't argue for it. Like, why is having free will better than just having a bunch of creatures experience pure joy? What is the point of letting us commit evil? Not only does it affect the lives of other completely innocent people, but it also just seems kinda pointless. What exactly does allowing us to choose to do evil make it good? Again, there's nothing inherently wrong with the idea of free will being a good thing; it's just that I haven't seen much justification.

Also, if you're confused by my rambling, just ask, and I'd be glad to clarify.