All female birds are hens but not all hens are female. In the days when fowls were kept purely for eggs domestically there was no roosters so the name hens popularly stuck to chooks in general.
btw. A cockerel is generally thought of as a young rooster before it is able to breed.
Yes, it is confusing.