One possible version:
June 8, 20XX
Dear Sir,亲爱的先生
I'm sorry to tell you that I can't go to school today, I've caught a cold because I swam in the school's swimming pool yesterday.
我很抱歉地告诉你今天我不能去上学,因为我昨天在学校游泳池里游泳,我得了感冒。
This morning I had a headache. After taking my temperature, my mother found that I had a high fever, immediately she took me to see a doctor, who advised me to stay in bed for 2 days. Now I am writing to you to ask for 2 days' sick leave.
今天早上我头痛。走了我的体温后,我妈妈发现我发烧了,她马上带我去看医生,他建议我卧床2天。现在我写信给你要2天病假。
With best wishes致以最良好的祝愿
Your student,你的学生,
Tom汤姆