So our day to day, sometime moment to moment, immune system function is a factor in who gets sick from a microbial invader. The virulence factors of that particular microbe are also a big factor in the microbe's success at beating your defenses. Opportunistic pathogens- microbes that are usually able cause infection only in the immunocompromised. Remember this is not cut and dried. Sometimes an opportunistic pathogen can be a frank pathogen in a different body site or with one tiny change in the microbe's genes that gives it a new virulence factor.
Microbes have many many related species and very few cause infectious disease.
Gene mutations and gene mixing between microbes coupled with selective pressure . I've organized the infectious diseases into types of microbes first and then by structural characteristics . Structure is the key to function . Use all you've learned about structure, metabolism, genetics, control methods and the immune system to understand disease and how to conquer it. Pathogenic bacteria like to live in the particular conditions found in the human body.