A vaccine is a weakened or dead form of a virus that contains the antigen of that virus.
An antigen is a protein on the surface of the virus that allows the body to identify it.
Specific T helper cells from the body's immune system detect the antigen and, because of this, stimulates specific cells in the body known as B cells.
These B cells divide through a process called mitosis to form a genetically identical duaghter cells known as a plasma cells.
This plasma cell produces antibodies spefically against this virus.