<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def append(self, data):
 """Append a section to the body. :param data: The data to append. :type data: str or bytes """

        if isinstance(data, six.text_type):
            self._message.add_body_data(data.encode(self._encoding))
        elif isinstance(data, six.binary_type):
            self._message.add_body_data(data)