How to change the lower version of Android AOSP from upper version

I have Android 10 source code using repo sync release of LA.UM.8.6.2.r2-02400-89xx.0.xml, I want to downgrade to Android 8 release LA.UM.6.7.r1-07200-8×09.0.xml. Can you please guide and list command to downgrade.