Moodle 4.1 or later requires at least PHP 7.4.0 (currently using version 7.3.33). Some servers may have multiple PHP versions installed, are you using the correct executable?