Mechanisms of coexistence of a bacteria and a bacteriophage in a spatially homogeneous environment