The earth would have to be over the moon to cast a shadow on top of the moon, which is where the shadow came from. That's just reality.
.
Your fake model is the problem. The sun and moon are not always on the same side of the earth.
.
That's just reality.
.
If you're stuck in a "flat-earth" model obviously you won't be capable of understanding the diagram.
.
The earth isn't casting a shadow "on top of the moon."
Earth is casting a shadow on the visible face of the moon. (On its side not its top.).
There is a visible face, which always faces the earth, and the far side of the moon which is never visible from earth.
.
That is, in our times it isn't visible. There may come a time when the far side gradually becomes more visible from earth.
.
But that could be many thousands of years in the future -- if the world lasts that long.
.