[Rebekah] was told, “The older will serve the younger.” As it is written, “Jacob I loved, but Esau I hated.”
Romans 9:12-13 ESV
This is ultimately about the election of Israel over all other nations, not about the salvation of individual people.
Both Esau and Jacob were children of promise. God prophesied that Esau would serve Jacob, but the birthright was still Esau’s to lose. He gave it up because he despised it, and then Isaac confirmed Esau's choice when he blessed Jacob, even if he believed he was blessing Esau.
Not even God is allowed to break his promises once made, so the blessing of Isaac on Jacob was made even more unbreakable by the three-fold word of God, Esau, and Isaac. The transfer of the blessing from Esau to Jacob required the cooperation of everyone involved: Isaac, Rebekah, Esau, and Jacob.