The plugboard (Preferences: Metadata Plugboard) is a device sensitive tool for cases like yours, to allow you to inject Calibre metatadata into the documents standard fields.
ex. I insert {series_index}- into the Title for my Kindle
The best way to learn is to Launch the tool and explore

Templates are the standard ones used elsewhere in Calibre (There is a fairly large section covering simple to advanced usage in the Online-Calibre Help)