Why put the Tree of Knowledge in the Garden of Eden? Two words: free will. God wants us to obey him freely, not just because there's no other option. For that reason did he put the tree in the garden. Adam and Eve exercised their free will, ate of the tree of knowledge, and were consequently punished.

If you're not going to give people free will, why create them in the first place? It only makes sense if you're psychotic.

See also: missing the point