There are different types of emails a student can get, one such email is the one they get immediately after enrolling in a course.
Please note: The LMS is responsible for mentioning the course that the student enrolled for (dynamically) at the top of your message, so there is no need to try and put them in your own message.