The android manifest xml file does not contain that information. The android.yml file does. After altering it the apk build command doesn't make the apk file. Is there any build.gradle file or tool that can be used to edit version number?
Procedure:
apktool d myapk.apk
open apktool.yml, increment versionCode and save
apktool b
Followed by jarsigner and zip align
Similar: can I change version code from apk?