code: def add_attribute(self, path, name, value):
          
          node = self.add(path)
          node.attribs.append((name, value))
          return node
docs: Creates the given attribute and sets it to the given value.
          Returns the (new or existing) node to which the attribute was added.