How do I use templates in my own plugin

I am working on a plugin, that creates Markdown notes for images, that include all EXIF data of the image as YAML properties. Before inserting these properties, I want to create the file and apply a configurable template using Obsidians core template plugin.

The template could - for example - include tags, created and other properties.

Is that possible?