The above answers are for Elasticsearch.
Follow this document for Opensearch. there is more you need to do to make it work:
https://docs.aws.amazon.com/opensearch-service/latest/developerguide/managedomains-snapshot-registerdirectory.html