He knew no sin became sin that we might become his righteousness.
When the Lord took upon himself the burden of our sin (which is not the same thing as being guilty of sin as though he had committed those sins) he became a curse. A curse was unclean and thus separated from the camp. This showed that he, on the cross (cursed is everyone who hangs on a tree), somehow was outside of God’s people, but in so doing conquered death by the love of God thus proving the justice of God and being resurrected that we may know that he is King of kings and Lord of lords.
God Bless