The Federation service still available on Windows 2022 and 2025.
Microsoft recommend to use Entra ID instead of federation service if possible in case of upgrade.
In other hand there is no official date of end of support.
Below is Microsoft article talking about ADFS under Windows 2016 until Windows 2025
Please don't forget to accept helpful answer