I don't think you can define rules in the Marketo formula fields to extract and store a part of the field's value. Also, formula fields have several limitations, e.g., they aren't supported in smart campaigns, cannot be exported, and emails with formula fields in them cannot be sent via batch campaigns.
IMO, If the domain is not set during the lead creation, you'd want to populate the domain by calling a webhook-compatible service from the flow that could extract and return the domain address of a person back.