According to the CDC, here is the definition of vaccine/immunity: https://www.cdc.gov/vaccines/vac-gen/imz-basics.htm
Immunity: Protection from an infectious disease. If you are immune to a disease, you can be exposed to it without becoming infected. Vaccine: A product that stimulates a person’s immune system to produce immunity to a specific disease