There is currently no way to explicitly lock the (so called) "tango monitor" (i.e. mutex) of a device. For devices dealing with dynamic attributes, locking device monitor is the only way to add/remove attributes under critical section in a safe and clean manner.
In C++, one can do:
myDev->get_dev_monitor()->get_monitor();
…. protected code
myDev->get_dev_monitor()->rel_monitor();
The python API could provide shortcuts attached to the DeviceImpl class (e.g DeviceImpl.lock_monitor and DeviceImpl.unlock_monitor). Something compatible withe the python "with" keyword would even be better.
You are the second person to ask for this.
I will make it available for the next PyTango release.