I have never heard of such a restriction regarding a hard drive but you don't mention what model make or any details as to which one you bought. But most importantly you should know that installing a newer or different MacOS version will NOT increase the MacBook Air storage capacity, for that you need a larger compatible Drive, or at least an additional external drive or drives.
You could check here which is a very reliable Mac supplier if your model is supported which it appears to be:

SSD Upgrade Kits for MacBook Air 2013 - 2017
Upgrade your 2013-2017 MacBook Air hard drive to an SSD for 16x the capacity and 5.8x faster speeds of the original drive. Kit includes all tools needed.

Or even any of their external drives, preferably external solid-state drives if you need to go with the external drive route.
For other details about the 2017 MacBook Air, check the specs and details here:
MacBook Air "Core i5" 1.8 13" (2017*) Specs (13-inch, 2017**, MQD32LL/A*, MacBookAir7,2, A1466, 3178): EveryMac.com
Technical specifications for the MacBook Air "Core i5" 1.8 13" (2017*). Dates sold, processor type, memory info, hard drive details, price and more.
PS: welcome to ehMac.ca forums, and I'm just a bit curious and wondering why your 2013 MacBook Air apparently just died as you stated as it should have a fair bit of life left in it still even if it is getting on in age.
- Patrick
=======