Professional tools like Adobe Photoshop or free online editors like Canva let you type directly over an image and save it as a JPG.

If you want to create an image with text on it (like a caption or a quote):

Websites like ImgOCR and imagetotext.info allow you to upload a JPG and download the extracted text as a .txt file.

You can use Microsoft Word by inserting the JPG, saving it as a PDF, and then reopening that PDF in Word to convert it into editable text.