Aluminium metal belongs to group 3 and it looses three electrons to form Al³⁺ ion. While, Sulfur belongs to group 6 and accepts 2 electrons to obtain noble gas configuration and forms S⁻².
The compound between Al and S is made in such a way that the nuber of Al atoms present in compound are multiplied by the charge number of sulfur (i.e -2) and number of Sulfur atoms are multiplied by the charge number on Aluminium (i.e +3),