died for our sins?

if that were true, then psychologically, people could & would do anything, because someone else was/is/going to be punished for whatever they do. realistically, that would be unjust, & The God is not unjust, no one can bare the sins of another, we are responsible for our own actions. that would be like, if a judge has two people n his court, one horrible, lies, steals, betrays, harms others, etc. & the other, good, righteous, respectful, would never hurt a fly. so, instead of punishing the guilty one of evil deeds, he punishes the good one. even the courts, as corrupt as many are, would not allow a person to take the blame & consequences of the guilty when they know, without a shadow of doubt, that the guilty is guilty. so, if the courts will not allow it, why would one believe The God, Whom One of His Names is “The Just” & commands justice forbids false witness, forbids killing, oppression, lies, theft, adultery, etc. all the things that are punishable, not punish the guilty but punish the innocent?