Your motherboard is of Form factor: uATX, and it also has one 1 PCI Express x16 (Gen3.0) slot for the GPU. You can use any GPU, but whether it will fit will also depend on the size of your ATX cabinet. Problem is, some of those high-end RTX 2070 and GTX 1080 Ti models, not all, might be slightly bigger to fit inside that HP envy cabinet.
You need to check the GPU before buying, as to whether it will fit easily in your HP machine. Regarding the PSU, that HP system comes with an internal 500Watts unit, (100V-240V), which might sometimes work, but I won't advice you to use this prebuilt PSU to power up any of those cards. Upgrade your current power supply unit to a min 550-600 watts high quality PSU from reputed brands like Seasonic, EVGA, Corsair, FSP, OCZ, Antec,and other similar brands.
As you can see from this database, most of the RTX 2070/1080 Ti cards are having a min length of 8 inches, and it goes all the way to 12/13 inches in length as well. Most of these cards are dual slot in width though.
https://www.techpowerup.com/gpu-specs/geforce-gtx-1080-ti.c2877
https://www.techpowerup.com/gpu-specs/geforce-rtx-2070.c3252
Is this your cabinet ?
https://support.hp.com/in-en/document/c04918486