In higher vertebrates, the immune system can distinguish between self-cells and non-self. If this property is lost due to genetic abnormality and it attacks self-cells, then it leads to autoimmune disease.
When a host is exposed to antigens, which may be in the form of living or dead microbes or other proteins, antibodies are produced in the host body. This type of immunity is called active immunity.
The exaggerated response of the immune system to certain antigens present in the environment is called allergy.
Graft rejection occurs when the recipient's immune system attacks the donated graft and begins destroying the transplanted tissue or organ.