If you want to show the message on another page or in a widget you’ll need to store this somewhere.
The logical place would be a new entity either persistent or non-persistent.
You might also consider to pass the error message, that you have created in a microflow, to an attribute of the entity for which you show the new page.