@keneda I have finally installed it I do not know what of this was crucial and what not or not but i put it all here for others to use:
Mobile was, after several failed installation attempts in a status in which it only could boot to Fastboot both Recovery and System did not work.
i have used a computer with Intel chipset running Ubuntu 20.04. Because in the computer with Opensuse Tumbleweed with AMD chipset it was not working and had led to previous status.
I have used a USB 3.0 port with a short (8 cm) cable USB A to USB C.
I have installed adb and fastboot using the following (the other ways did not work):
sudo apt install fastboot
sudo apt install adb
I have installed the Android 9 stock image in the way similar to what is described by @scream314, using the image on the link shared in his post https://forums.ubports.com/topic/6951/ubports-quick-and-simple-install-on-xiaomi-mi-a2 (thank you).
But
-
used the 3.3.1-0 version of the TWRP instead. The one shared in the post did not work for me.
-
Before installing I wiped and formatted the mobile as shown here: https://www.youtube.com/watch?v=sqmng9WQFkI&t=0s 9:11 minutes
-
I also changed the slot manually between the installation in Slot A and B, in the reset menu of TWRP and I did not reset between the installation in slot A and slot B.
-
Instead of using sideload I just copied the Image using the files App of Ubuntu and "copy to" as you would do to an USB stick. The Mobile will appear as an storage after formatting it.
After installing Android 9, i had to reset the mobile twice before System Android 9 could start and exercise some patience. I did the absolute minimum Android setup.
I enabled developer options and USB debugging.
(At this point, i tried to install then permanently TWRP in the Recovery (as indicated in the mentioned video), but it did not work, in fact I lost the Android 9 installation by trying to do it it and had to install it all again, but it was not necessary either).
Then I downloaded and installed the APP (0.8.9) in the computer, but not from the link in the device page (did not work) from the Ubuntu App store.
Then I have followed the instructions of the App with the following details:
Did not select Wipe Personal Data
Selected 16.04/arm64/android9/rc
(/stable did not work and brought the Mobile to a status in which I had to do everything again from the start).
After running Ubuntu for the first time,I forgot to install the SIM before and after Mobile Data could not be activated. I solved it by doing an "Erase and Reset All". So suggest do not forget that.
Hope it helps and thank you to all from which I grabbed info.