Superconductivity in the Fröhlich two-dimensional model with an arbitrary carrier concentration