God allowed Satan to tempt humanity.
The Bible includes many things that are difficult for us to accept. One such truth is that, when GOD put Adam (and subsequently created Eve) in the Garden of Eden—which GOD Himself formed and caused good trees to grow within—GOD allowed Satan to tempt (and introduce sin) to humanity.
8 Then the Lord God planted a garden eastward in Eden, and there He put the man He formed. 9 Besides this, God caused every tree beautiful to the sight and good for food to grow from the ground. Also, in the middle of the garden were the tree of life and the tree of learning the knowledge of good and evil. ... 15 Then the Lord God took the man He formed and put him in the garden to tend and keep it. 16 And the Lord God commanded Adam, saying, “You may eat food from every tree in the garden; 17 but from the tree of the knowledge of good and evil you may not eat; for in whatever day you eat from it, you shall die by death.”
3:1 Now the serpent was more cunning than all the wild animals the Lord God made on the earth. And he said to the woman, “Has God indeed said, ‘You shall not eat from every tree of the garden’?” 2 And the woman said to the serpent, “We may eat the fruit from the trees of the garden; 3 but from the fruit of the tree in the middle of the garden, God said, ‘You shall not eat from it, nor shall you touch it, lest you die.’ ” 4 Then the serpent said to the woman, “You shall not die by death. 5 For God knows in the day you eat from it your eyes will be opened, and you will be like gods, knowing good and evil.” 6 So when the woman saw the tree was good for food, was pleasant to the eyes, and a tree beautiful to contemplate, she took its fruit and ate. She also gave it to her husband with her, and he ate.
(Genesis 2:8-9, 15-17; 3:1-6 OSB)
If, as we established, Satan first introduced sin in the heavenly realm, why didn't GOD immediately judge and punish Satan before he could corrupt the earthly creation?
So much pain and death could have been avoided if GOD had just stopped Satan right away!
Ultimately, if we trust that GOD has our best interest at heart, we must rest in faith that GOD saw that this was the best (or, perhaps even, the only) way for things to go.