I have macOS Monterey version 12.4 I realised that I needed to upgrade my macOS to version 13 upwards before I could download Xcode 14, which is what I am currently doing. My memory is a bit low as well for the upgrade, and I’m trying to empty some files to accommodate the new version. Once I’m through, I’ll let you know the progress.
The easiest way to do that and have every appearance of that changed, is to select the name, then right click and select Refactor then Rename. Xcode will search for all the locations where that name exists and all you do is change the one you selected (it will be highlighted) and all the others will be changed simultaneously.
Since you are changing the file name you can also include the name that is in the file header comments (see the arrow in the image above) so that keeps the naming synchronised.