docs: def _add_element(potential, var, potential_tag):
          """
          Helper function to add variable tag to the potential_tag
  
          Parameters
          ----------
          potential: dict
              Dictionary containing Potential data.
              For example: {'role': 'Utility',
                            'Variables': ['D0', 'D1', 'C0', 'C1'],
                            'type': 'Tree/ADD',
                            'UtilityVaribale': 'U1'}
          var: string
              New Element tag which needs to be added to the potential tag.
              For example: 'type'
          potential_tag: etree Element
              etree element which would contain potential tag
              For example: <Element Potentials at 0x7f315fc44b08>
                           <Element Branch at 0x7f315fc44c88>
                           <Element Branch at 0x7f315fc44d88>
                           <Element Subpotentials at 0x7f315fc44e48>
  
          Examples
          --------
          >>> writer = ProbModelXMLWriter(model)
          >>> writer._add_element(potential, 'State', parent_tag)
          """
          if var in potential:
              etree.SubElement(potential_tag, var).text = potential[var]