WEB-8397 Incorrect "element is not allowed here" inspection
(cherry picked from commit 0efd929) CR-WS-126