Template - Something that serves as a model for others to copy: "a template for change".
Theme - Give a particular setting or ambience to (a venue or activity): "themed menus".
So in essence, looking at the definition, a template usually refers to a frame. A set of building blocks grouped in a given way which lets you fill it with your own content. A template usually infers more than merely the aesthetic feel, different templates usually involves different layout, different means of navigation etc.
A theme however usually revolves around the same frame ("template"), and merely sets the aesthetic shell of the website. A theme usually sets the colouring, fonts, style etc. Another term you usually see used for theme is "Color scheme".