Insert an attribute into an attribute list.
If an attribute with the same name is already present,
then the value of this attribute is changed to f newValue oldValue.
The function name is analogous to Data.Map.