because you got it backwards
"Traumnovelle" was the start
go look it up
mask stands for secret societies, have you read the book ?
to cap it shortly,
doctor goes to secret meeting, is found out, someone else takes the blame, his wife knows what happened and shows him by leaving the mask on his bead (from the secret meeting)
but is is written so it can be seen as only beeing a dream that happened to him.
ergo hiding in plain sight.
language is key.
kubriks version is more blatantly.
the giving away of their child isn´t in the book version