Settings > Screen Time > Content & Privacy Restrictions > iTunes & App Store Purchases > Installing Apps - set to Allow
If you have forgotten the ScreenTime (a.k.a. Restrictions) passcode, one of the two procedures outlined within this link should resolve the problem:
If you forgot your Screen Time passcode - Apple Support
For devices capable of being updated to iPadOS 13.x and later (not applicable to your iPad Air) it is possible to reset a forgotten ScreenTime passcode without wiping the iPad. To reset a forgotten ScreenTime/Restrictions passcode on older versions of iOS, the iPad must be reset “as new” - losing all locally stored data. In this situation, you’ll not be able to restore your data from an iCloud or iTunes backup - as the forgotten passcode is integral to the backup.