Templates are used to create new issues with prefilled values. Templates are not issues which means all information you put into it is stored in the app's database (e.g. template's name, and description).
After a new issue is created from a template, the app doesn't know about any changes on that issue. We store information about date, user and template from which the issue was created. When you delete a template, all related data is removed from the app's database permanently.