Without the latest php you could be missing out on some newer features or as nextcloud updates, find some features deprecated. The nextcloud website does recommend having php 8.1. Unless you are die hard Debian user, I would install it on an ubuntu 22.04 container.
But that being said, for what it’s worth, I ran nextcloud on ubuntu 20.04 with php 7.4 until just a few months ago and I didn’t have any issues.
thanks for the response @hulxmash , I actually created another container in Proxmox with Ubuntu 22.04 and PHP 8.1 installed, so it seems to me that Debian 11 is the reason for the PHP 7.4 install. Not 100% sure though, I could have made an error during the Debian 11 install.