I have solved this problem with N1QL instead of subdocument API. Bevause subdoument API prevents all operations if ever, a STATUS_PATH_EXISTS error arises.
I am leaving my DSL in case someone else searches for a solution:
final Statement statement = update("bucketname")
.set("devices", arrayPut("devices", "value1", "value2"));
This simply add value1 and value2 to devices attribute of the document with id “id” in. It automatically neglects already existing values. If value1 already exists in devices array, it will be skipped.