Surface field in an ensemble of superconducting spheres under external magnetic field