How to solve CORS policy problem for Strapi?

Hello.
I need to create config/middelware.js

Is necessary to say to strapi to use this middelware somewhere in settings or this is an automatic process?.

Postman dosen’t show Access-Control-Allow-Origin:*

It is ok? how can I check is working propely.