Trying to Analyse a WIFI Hardware Problem
This blog gives an account of the information contained in NVRAM:

https://eclecticlight.co/2018/08/24/whats-stored-in-nvram/

It also gives the Terminal command nvram -xp to list the contents of the NVRAM, which might be useful. Note that the data is in base64 encoding, which will need further decoding to become 'human-readable'.

However, there does not seem to be anything specific to WIFI or networking generally. I note that Internet Recovery Partition, which is in Firmware, can remember Wifi router selection and passwords.

Given the age of the machine, an intermittent failure of this sort is likely to be a hardware problem. You could try ruling out software issues by booting to a new, clean OS on an external disk. 

As to why NVRAM reset fixes it: that's unknown.  If the contents of NVRAM are unchanged when the WiFi is defective and when it works, then it's not the reset as such that's fixing it. It's possible that the reset does something else coincidentally.