A helium balloon rises upwards due to the force of buoyancy exerted by the air it displaces. As helium is lighter than air, the total weight of air that the balloon displaces is more than the weight of the balloon and the helium gas filled in it.
With an increase in altitude, the density of air decreases. This reduces the weight of air that the balloon can displace. At the same time, there is also a reduction in the air pressure which allows the balloon to expand and displace more air. But a balloon can only expand to an extent that is permitted by the elasticity of material it is made of.
When the balloon has expanded to its maximum possible volume and the buoyant force due to air is equal to the weight of the balloon it stops rising upwards.