How have you configured the Template node? The default is to send the contents as plain text. If you want it to parse the template as JSON and to send the Object, you need to change the "Output as" option to "Parsed JSON".
But if you want it to do that, then you need to ensure the Template is valid JSON. Your current contents is not JSON - you need to put quotes around name:
As a convenience, if the text is valid JSON, then the node has an option to parse the generated text from JSON to a JavaScript object. If you didn't use that option, this is the same as putting a JSON node after the Template node.
So the only way to have the Template node send a JavaScript object is for you to enter JSON in the Template node and have it parse it for you.
If you actually want it as a JSON string to make it available via a http endpoint, then your original config should do that, except that you need to put valid JSON in the template. So in the template put {"name": "Fred"} and don't tell the template to convert it from JSON to an object. In the following function node you don't need the JSON.stringify() call as it is already JSON.