That works for me.
Just to clarify, your device will be set in Access Point mode, and using your computer you can connect to it as a wifi access point. Once you do it will open a page (automatically) where you can insert your wifi credentials and hit save. The information will be saved and the device will now switch to your wifi and it will be discovered automatically on Home Assistant ESPHome addon.