You can hide incoming messages on your Samsung Galaxy S10 by changing your Notifications preferences, or hide the Messages app with a third-party app.
You can search all of the messages on your iPhone in seconds using the search function in your Messages app or Spotlight to find specific messages.