Lots of factors can leaded to immune suppression just to name a few:
Some Diseases as you point out.
Drug Treatment: Any Immunsupressive Treatment(many chemotherapy drugs, Cortical Steroids, Target therapy), Radiation Therapy, Side effects from certain drugs(off target effects).
Stressors: Physiological State, Nutritional State(Vitamin deficiencies and Undernutrition), exposure to toxins/pollutants
Other: Overall health(weight, Age, Sleep etc.), Pregnancy(maybe), Microbiome status
In addition to the above mentioned conditions other conditions that can decrease immunity is infections. Viral, bacterial, and fungal infections can decrease immunity. Stress, already mentioned is another condition that decreases immunity. Of course immunosuppressive drugs are meant to reduce immunity. Omer
When working optimally, the immune system can prevent sickness when we're exposed to germs. Several factors like sleep, diet, stress and hygiene can affect the immune system's performance, and any offsets in these behaviors can cause havoc on immune function.