RAZ-3506: Handle circular references in label paths
- Added check to handle circular references
- Added checks to make sure label_id and parent_label params passed exist in database to prevent orphans