Is it an Apple silicon or Intel machine? Intel macs are crazy slow - especially since the most recent few versions of macOS. And especially since developers everywhere have upgraded to an M1 or better.
You could certainly still buy new intel macbooks 3 years ago from Apple. Plenty of people did - particularly given a lot of software was still running through rosetta at the time.
The M1 air was only released in November 2020. With a bit of slop in the numbers, its very possible the parent poster bought an intel mac just before the M1 launched.
Yeah it's such a shame how much the performance has been affected by recent macOS. I kept my 2019 Mac Book Pro on Catalina for years because everyone else was complaining... finally upgraded directly to Sonoma and the difference in speed was night and day!