The spirit of God could have inspired things such as:
Thou shalt not own slaves.
Thou shalt honor men and women as equals.
Thou shalt respect thy neighbor.
Thou shalt not hit children.
I see......you would want to dictate to God what he should and shouldn't do, but chafe if God wants to tell you what to do.....
What God instituted in the beginning was a perfectly balanced arrangement. Humans thought they could do things better by making their own rules, so God let them see where that would take them.....what you are criticising is what man did...not what God did. He simply regulated their choices to accommodate fairness as much as possible within the framework that they had chosen.