The bacteriophage in question is "rough-specific," i.e., not capable of infecting encapsulated bacterial cells, primarily due to an impaired adsorption of the bacteriophage to the smooth bacterial cell surface and the inability of the bacteriophage to degrade the capsule. The (acquisition and) expression of plasmid-borne (viz. Rabindra's answer) capsule-biosynthesis genes by a bacterium leads to the formation of a capsule, the "smooth" phenotype, and the resistance of the encapsulated bacterial cell to the rough-specific bacteriophage.
---
Article Escherichia coli K1's Capsule Is a Barrier to Bacteriophage T7
In fact I sequenced the genome of the phage-resistant bacteria strain. Compared to wild type, there is one point mutation in the phage-resistant bacteria. This mutation causes one gene defection. And the gene is associated with the synthesis of colanic acid and LPS.
So I doubt if this point mutation leads to the colanic acid accumulation and to the resistant phenomenon?