That is a good question :)
My understanding of what you are asking: How come, Adam and Eve, did not "have it in them", to choose correctly, to choose to obey the commandment.
In short: there is no, purely logical answer to this.
This question basically boils down to these types of questions:
- why did (how could) God create a creature that could choose poorly?
- did God know what we will fail?
- why didn't God create us without what is necessary to choose well?
These questions have preoccupied many theologians and I hate to disappoint you, but I have not yet heard a satisfactory explanation.
We can, logically & philosophically understand a LOT around those questions. We can understand that free-will necessarily must allow us to choose badly, that God cannot create contradictions (therefore cannot create a creature with free-will without the capacity to choose badly) etc.
But we cannot, in purely rational & logical way, understand the full mystery.
The big question remains:
"why is existence with free-will more valuable then non-existence"
Existence without free-will is not difficult to dispute as inferior, but the superior value of "existence with free-will", and therefore, a chance of eternal hell, IS A MYSTERY.
resources on this topic
there is a ton of literature on this, but also some good video resources in form of debates for example. search "problem of evil" or other variations on your tube, and you will find a summary of views of many theologians on the topic.
My personal, alternative understanding of the story of the fall
This is not an orthodox understanding of it, this is a different look at this story that helps me understand some of the mystery:
Maybe, God's commandment to not eat from the tree of knowledge is NOT a commandment, in the sense of "do not do this, or I will punish you"
Instead, the commandment is a warning of a natural consequence - IF you do eat from this tree, THEN you will die - ie, something pretty bad will happen.
Maybe, "knowing good and evil", necessarily results in a perpetual struggle to choose good.
So, we could understand this as, not that Adam and Eve did not obey, per sa, but that they choose to struggle, they choose to know good and evil. Like a child that wants to find out for it self what fire feels like.
In this understanding, God fully knew that we will have to know, but offered as an easy way out if we trusted Him.
anyway, just some personal thoughts :) Not sure if they help you understand this mystery in some way or not.