Yoga is commonly thought to be a form of physical exercise, when, actually, Yoga works with the mind.
The goal of Yoga is to know oneself on all levels, physical, mental, and spiritual. The instrument used for this exploration is the mind, and the process is meditation. But before the mind can meditate, it must be focused and calmed.
Bringing the mind to serenity and one-pointedness is the main work of Yoga. To calm the mind requires pacifying the emotions, and cultivating "vairagya," which means detachment from the things the mind clings to. To step from here to there requires letting go of the place I'm standing. This ability to let go of what I'm holding onto is vairagya.
At the same time a yoga practitioner cultivates vairagya, s/he engages in practices to create the ability to focus the mind and hold it on a single point for an extended time.
All of this happens in the mind. Physical postures are popular these days, and they play a role in the grand scheme of Yoga.
The heart of Yoga is meditation, which is done with the mind.