The Deacon has a defined role and functions when he is present and serving at Mass. The United States Conference of Catholic Bishops (USCCB) has a good article on The Deacon at Mass which goes into a fair amount of detail on the subject. The link to the USCCB article is provided below for anyone who wishes to read more about the topic.
Link to USCCB Article "The Deacon at Mass"