If you absolutely need version 5.1 (e.g., for a specific plugin that never got updated), install Parallels Desktop or UTM and run macOS Mojave inside a virtual machine. Then install P-touch Editor 5.1 inside that VM. This gives you a "top" stable environment without risking your host OS.
Depending on your Mac's age, you have two primary ways to get the software: App Store (Recommended for Modern Macs) If you are running macOS 13.0 or later , the latest P-touch Editor is available directly on the Brother P-touch Editor Mac App Store page Brother Support Website (Legacy or Specific Models)
Depending on your macOS version, your download path may differ.
Version 5.1 uses a legacy CUPS backend. Go to System Preferences → Printers & Scanners. Remove the printer, then re-add it using the IP address (for network models) rather than Bonjour. Use protocol HP Jetdirect - Socket on port 9100.