<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_attribute(self, name, value):
 """ Adds given attribute to the node. Usage:: True [u'attributeA'] :param name: Attribute name. :type name: unicode :param value: Attribute value. :type value: Attribute :return: Method success. :rtype: bool """


        if not issubclass(value.__class__, Attribute):
            raise foundations.exceptions.NodeAttributeTypeError(
                "Node attribute value must be a '{0}' class instance!".format(Attribute.__class__.__name__))

        if self.attribute_exists(name):
            raise foundations.exceptions.NodeAttributeExistsError("Node attribute '{0}' already exists!".format(name))

        self[name] = value
        return True