New versions of Composer packages published on Packagist.org are not available via Composer 1:
new packages and old unused packages will only be visible to Composer 2 until someone installs them, at which point they will become visible to Composer 1 as well (within 24h as this process happens on a nightly basis).
Magento < 2.4.2 does not support Composer 2.
How to install or upgrade a third-party module from Packagist to Magento < 2.4.2?
Install Composer 2 alongside with Composer 1.
composer2 require --ignore-platform-reqs --no-plugins <your package>
As a side effect, this step could undesirable upgrade some other packages to versions which require PHP newer than you have installed.
It is fixed by the Step 3.
This step will revert other packages (mentioned on the Step 2) to a compatible PHP version.