Same issue, on iPhone and iPad, started with upgrade to iOS 18, not fixed with 18.0.1.
I can access the same accounts fine from a desktop MacOS Mail app.
Dovecot (v2.3.20) debug logs show a successful TLS connection and authentication, opening the INBOX, executing LIST, then immediately disconnecting. No errors reported on the server side.
I also run a slightly older version of Dovecot (v2.3.17) on another server and my iOS devices can get mail just fine. I'm wondering if the iOS 18 clients are doing something slightly non-standard causing newer Dovecot versions to close the connection.