It was set in stone and the prophesies would be fulfilled. God the Father had a Master Plan to bring the world to His saving grace through the blood that was shed by His one and only Son. This plan was foretold in the Old Testament and was fulfilled to the letter in the New.
Surely he has borne our griefs and carried our sorrows; yet we esteemed him stricken, smitten by God, and afflicted. But he was pierced for our transgressions; he was crushed for our iniquities; upon him was the chastisement that brought us peace, and with his wounds we are healed. All we like sheep have gone astray; we have turned—every one—to his own way; and the Lord has laid on him the iniquity of us all. – Isaiah 53:4-6 (ESV)
Yet it was the will of the Lord to crush him; he has put him to grief; when his soul makes an offering for guilt, he shall see his offspring; he shall prolong his days; the will of the Lord shall prosper in his hand. Out of the anguish of his soul he shall see and be satisfied; by his knowledge shall the righteous one, my servant, make many to be accounted righteous, and he shall bear their iniquities. Therefore I will divide him a portion with the many, and he shall divide the spoil with the strong, because he poured out his soul to death and was numbered with the transgressors; yet he bore the sin of many, and makes intercession for the transgressors. – Isaiah 53:10-12 (ESV)
What Jesus accomplished on the cross was an eternal transaction between Him and The Father. Isaiah 53 makes it clear that He did not die for His own sins, he had none! He made Himself the sacrifice for all the sins – past, present, and future – of those that would come to Him!