You may come across some different ways of removing WordPress version from the head tag. The preferred way of how to remove WordPress version from the head tag is mentioned in this article. The reason to be preferred is that it will remove WordPress version information from both site and RSS feeds.
Within your themes folder, open functions.php file and paste the following code.
Preferred way of how to remove WordPress version info
This is how you can remove WordPress version information not only from the site but from all the locations.