Office 365 does not allow sending mail with a sender other than the configured mail

I have configured the magazine correctly and the mail server works to reset the password, etc.

smtp = On

smtp_server =
smtp_port = 587
smtp_auth = tls
smtp_username =
smtp_password = pasword

But in the options that the from is different from “”, as when they have to suar as from the mail of the main contact “” the messages do not arrive.

the errore message of the web server is the following:

SMTP Error: data not accepted.SMTP server error: DATA END command failed Detail: STOREDRV.Submission.Exception: SendAsDeniedException.MapiExceptionSendAsDenied; Failed to process message due to a permanent exception with message Can not submit message.

Any solution?

Thank you

This is an issue in progress here: