“Go away. The girl is not dead but asleep.” (Matthew 9:23)

Here is the situation:
When Jesus came into the ruler's house, and saw the flute players and the noisy crowd wailing (Matt. 9:22)
Jesus took her by the hand. She got up and recovered, and the news spread quickly:
News of this spread through all that region. (Matt. 9:26)
This indicates that his healings brought Jesus attention from the masses.

The healing of the girl was not Jesus’ mission. If it was, Jesus would have set up hospitals. Rather, his mission was to broadcast his teachings to the masses. How did he - or rather the Supreme Being - accomplish this?

Why did Jesus heal the girl?

And why didn't Jesus just heal everyone?

As for the premise that Jesus was just having mercy on people - this is not necessarily wrong, but it is not complete. If Jesus' purpose of healing this girl and others was just to help others, then why didn't he heal everyone? Why didn't he simply set up hospitals where everyone who was sick or had any physical problem could come and touch him and be healed?

Furthermore, why didn't Jesus heal everyone in the future? Certainly, his healing abilities had no restrictions. He could have healed everyone, right? Why didn't he - if his purpose was to help others' bodies. Why did Jesus leave so many unhealed?

Because this wasn't his purpose for healing people's bodies:

His healings brought attention to his teachings.

Today there are many ways to broadcast information to the masses, including television, radio and the internet. These mediums did not exist during Jesus' time. During Jesus' time, word of mouth was the central means of broadcasting.

This event illustrated that Jesus and the Supreme Being utilized this to help spread Jesus' teachings by attracting people to Jesus.

And what was the essence of his teachings? When Jesus was asked what the most important commandment was, he answered:
"Love the Lord your God with all your heart and with all your soul and with all your mind and with all your strength. This is the more important commandment." (Mark. 22:27-28)