Collation version corresponds to the glibc version (it was bumped to 2.39 in 24.05, this happens on each release with a glibc bump btw!)
fwiw this is just a warning, you identified the error correctly already:
Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.2.2 to 29.0.1.1)
My guess is that the nextcloud29 bump landed on 23.11 faster than on 24.05 and thus it thinks there’s a downgrade.
The 24.05 backported should’ve hit the channel by now (https://nixpk.gs/pr-tracker.html?pr=318112), so the issue should go away by updating your nix channel (or flake input).
For the postgresql thing, see PostgreSQL: Documentation: 16: ALTER COLLATION