Yes, in appropriate circumstances. A person whose rights or interests may be affected by the outcome can apply to be added as a defendant before judgment.
The court considers whether that person's legal interest is genuinely connected to the dispute.