If I understand you correctly, you have two classification tasks (so it would be multi-task not multilabel in the usual lingo).
In that case, you can just output 14 logits and then group them for the loss if you want.
More concretely, you could output a batch x 14 vector of scores (so no final activations) and organize your labels into two batch-sized tensors.
Then for F.cross_entropy_loss(output[:, :9], target_a) + F.cross_entropy_loss(output[:, 9:], target_b).
Best regards
Thomas