Groups with automatic deletion
Requires Azure AD Premium
As demonstrated in the documentation, only Microsoft 365 groups can be associated for the expiration policy.
As stated in the tool tip:
Expiration will only be applied to Microsoft 365 groups
You can try out in this demo with various groups created.