No. TOEFL Write an Email doesn't require a subject line, recipient address, or any other email-client formatting — the task interface asks for the message body, and scoring is based on whether that body addresses the required content points clearly and appropriately, not on formatting extras that aren't part of what's being tested.
Take the free TOEFL Benchmark Test and get your estimated band score in about 45 minutes.
The response format is the message content itself — a greeting, the body addressing the scenario's required points, and a closing. Spending word count or time on a subject line or formal header takes away from the 100-120 words that should go toward the actual required content, which is where your task-completion score comes from.
Since the interface doesn't ask for a subject line, treat the greeting and closing as brief (a line each) and put the large majority of your words toward clearly addressing every required point in the scenario — that's what's actually being scored, and over-investing in formatting details that aren't part of the task doesn't help your response.
Understand exactly what's evaluated in Write an Email responses.