First of all, you have to install an APK Editor for this. Open the editor and find WhatsApp. Then you need to click on Common Edit.
Here you can alter the version name easily. Finally, apply this in this Editor app. Now, install it. Yes, you have already nailed this.