If you need to store the actual file on MongoDB, then GridFS is the way to go (as suggested by @Sudhesh_Gnanasekaran). However there is an alternative – store a url to an image in your document.
For example, I have a business collection which has a field, logoUrl. This is a url to an actual cloud storage solution such as Amazon S3. It could also be a url to a CDN like Cloudflare or Fastly.
MongoDB used to have an application called Stitch that made S3 integration easy. It transitioned into Realm which may have a different process.
Otherwise, the manual process is straight forward:
A frontend/client-facing application allows a user to upload a file, the file is sent via an API to a storage solution (AWS S3, Google Cloud Storage, Backblaze, etc), the URL response from the upload is sent back and the record in the database is updated/created with the URL to the image.