This is probably because UE5.1 changed the Include Order, so the parameters used in 5.1 Target.cs files do not actually exist in 5.0.
The error that you posted mentions about them all.
Just go to these files and try deleting these lines:
D:\Documents\Unreal Projects\ProjectName\Source\ProjectName.Target.cs(12,3):
'IncludeOrderVersion'
D:\Documents\Unreal Projects\ProjectName\Source\ProjectName.Target.cs(12,25):
'EngineIncludeOrderVersion'
D:\Documents\Unreal Projects\ProjectName\Source\ProjectNameEditor.Target.cs(12,3):
'IncludeOrderVersion'
D:\Documents\Unreal Projects\ProjectName\Source\ProjectNameEditor.Target.cs(12,25):
'EngineIncludeOrderVersion'