The immune system consists of a complex network of organs, cells, and molecules that work together to defend the body from pathogens. The primary lymphoid organs, bone marrow and thymus, produce immune cells. The secondary lymphoid organs, including lymph nodes and spleen, contain specialized compartments where immune cells gather and respond to antigens. Immune cells travel between the blood, lymph, and lymphoid tissues to carry out functions like pathogen recognition and elimination.