... I just reconsidered my previous answer -- pydicom does in fact
create a new tag for you if it is in the DICOM dictionary (so it can
look up the tag and VR). So you can do:
ds.OtherPatientIDs = "new value"
In your line above, you have ".value" on the end of the left side,
which is why it is giving an error. The .value is needed only when
accessing data elements by tag number.
-Darcy