Welcome to the MS Q&A forums.
Classic SharePoint provided the ability to add a search engine and had a specific web-part for it. Out of the Box, Modern SharePoint doesn't provide this facility.
There is a community framework called SharePoint PnP that does contain some Modern Search web parts. I've pasted the link below for various search scenarios but there is a wider set of documentation around PnP Modern Search V4.0
https://microsoft-search.github.io/pnp-modern-search/scenarios/
Cheers
Steve