Not exactly. The mRNA fragments are instructions to build pieces of the virus. Your cells execute the mRNA instructions, build virus fragments, and _then_ the immune system notices all these unknown fragments and learns how to destroy them.
Then next time around B-cells and T-cells are primed from all this target practice and its a lot easier, even if the neutralizing antibodies wane.