Yes, use an Exchange Application access policy and scope to the mailboxes you want to have access to
https://learn.microsoft.com/en-us/graph/auth-limit-mailbox-access
However:
This only works for specific scopes, so in your case, you prob cant use this if you want to create mail