I found the trick. Your phone needs to be connected to the internet (wifi) when you scan the QR code. Otherwise the setup will fail. I wonder the esim activating data has been transferred through the internet. If no internet, it will show error.
This att store doesn't have public wifi. I used another phone as hotspot, and it worked (I didn't bring the 2nd phone at first).
It is a $15 lesson, because I paid three sim cards in total (2 esim, 1 standard sim) The agent gave me 4th for free...
The agent did scan the ICCID on the QR sim card, and also input the esim IMEI from my Xs.