Yoga is not a mere exercise, so you can practice yoga at any time.
Yoga can be a way of life. For example, in a large audience, you sit quietly and control your heart, not letting it get bored with the noise of the environment, you are practicing yoga. When you work, you focus quietly, and you are practicing yoga. When you sleep, you can put aside today’s troubles and fear of tomorrow’s uncertainty, and go to sleep quietly. This is one of the effects of the corpse method. You are practicing yoga at the moment.
Yoga is a kind of exercise that controls the body and mind, and the purpose is to obtain the calm of body control. Therefore, the yoga they designed is spiritual, and physical exercise is to exercise your spirituality.