I’ve used scan-to-email, but that is entire dependent on the mail server configuration requirements. That path is also unrelated to Windows, iPad, Mac, or whatever. That’s involving your printer and your mail server. That can also include needing to set up an app-specific password too, if your mail server requires that.
An ancient Brother MFC here (which predates AirPrint) works as expected, with the Brother iPrint and Scan app.
For a low-budget approach, iPad Notes app supports scanning.
For assistance with the HP gear, check with HP. Or replace it with gear that better meets your needs.
Preferably whatever you buy with AirPrint.
If y’all want us to look at whatever printer gear you bought HP or otherwise, you will need ro post the vendor and model info.