templates folder in your app folder is very similar to the
ui folder. The only difference is that binary stacks in the
templates folder will not be encrypted if your application uses encryption. This is done because LiveCode does not allow controls on a password protected stack to be copied. (Script only stacks will still be encrypted.)
If your application uses lots of templates for Data Grid's or other purposes then key makes your
app.yml file cleaner as you don't have to explicity exclude multiple binary stacks from being password protected.
Even if you don't use encryption it can still be beneficial to store stacks intended as templates in this folder for organizational purposes.