Maybe you could do it as outlined in the image below:
In the survey tab of your xlsform:
Data entry screen as seen in Enketo: when a wrong entry is made
Data entry screen as seen in Enketo: when a correct entry is made
Reference xlsform:
Email Regex.xlsx (8.7 KB)
To understand more on Regex
, you could have a look at our support article Restricting Text Responses With Regular Expressions which has plenty of examples that could be helpful for your day to day work.