I would just add an analogy of an infant that is written into the will of a grandfather. The inheritance is his even though he doesn’t understand it and in fact knows nothing about it. His inheritance is given into the safeguarding of his parents until the time that he is able to understand it and claim it as his own. Nevertheless, until that time, it is still his by inheritance.
As is described multiple times in the Bible, we are the children of God by adoption and as such heirs to the kingdom of God. Baptism is the adoption process. Not a perfect analogy, but I think it makes it easier to understand.