The quick answer is no but let me go into detail when explaining this.
When you complete your usual workout routine, you trigger a stress response in your body, which allows your body to respond and adapt to this stress to build up your strength. However, when you are ill, you are adding unnecessary stress to an already stressed body. It’s like adding water to a fire, its only going to make things worse.
However, if you’ve just got a runny nose and feeling a little under the weather- maybe a short low intensity workout will be good for you.
In general, the collective fitness mentality towards sickness has always been simple: if going to the gym can get others sick, then stay away. That counts for anything that involves you feeling gross! Try a home solution instead.
Doing a workout from home can be great, as you can decide the intensity and level of training you want to push yourself too.
On one of your sick days, try a day 2 body prep workout. This is low intensity but gets your heart moving. (Always check with a doctor and never push yourself too hard when feeling under the weather)