<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def stage_tc_create_tag(self, tag, resource):
 """Add a tag to a resource. Args: tag (str):
 The tag to be added to the resource. resource (obj):
 An instance of tcex resource class. """

        tag_resource = resource.tags(self.tcex.safetag(tag))
        tag_resource.http_method = 'POST'
        t_response = tag_resource.request()
        if t_response.get('status') != 'Success':
            self.log.warning(
                '[tcex] Failed adding tag "{}" ({}).'.format(tag, t_response.get('response').text)
            )