<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def AddValue(self, registry_value):
 """Adds a value. Args: registry_value (WinRegistryValue):
 Windows Registry value. Raises: KeyError: if the value already exists. """

    name = registry_value.name.upper()
    if name in self._values:
      raise KeyError(
          'Value: {0:s} already exists.'.format(registry_value.name))

    self._values[name] = registry_value