God uses the visions as His a way of communicating even to His children, like how it is written in the scripture that the your young men will see visions, he shows the visions to the kids in a very young age, and gives them the hope and the confirmation of His presence in their lives. There are multiple testimonies from kids who adore the Lord and they pray for the visions. God leads them to the transcendental state where they get to Heaven and they worship the Lord, being part of the Heavenly Kingdom.
Sometimes when the kids are in a very sad, scary and painful state, and they pray to God in their loneloness the Lord touches them with the vision, which helps them to move forward. It gives them the Hope to search for something that is new, and beautiful, they forget their worries and are so exicited about their vision and they start building their trust and faith in those visions.
Even in the middle of the most worsest situations, God brings in the most beautiful and promising visions to the kids, which enables them to grow up to be what they saw in the vision. Like the vision that Joseph saw in his dream in his childhood, which helped him to cross all the hurdles in life, till his vision came true.
It is not the imagination or thought but it is the vision that guides the children of God.