I would argue that "underwear" is an article of clothing intended to be wholly worn under one or more other articles of clothing. Bra -> shirt, for example.
The sock is worn under shoes and sometimes also pants, but can be worn exposed, see knee-high socks and miniskirt.
But the biggest reason I would say socks are not underwear is because shoes are not clothes. Shoes are outerwear, like a jacket or mittens.
Are shoes clothes?
