Can I use the same Apple ID for multiple Macs if I only need Apple ID to update macOS?
You can use a single Apple ID to log into a maximum of ten devices at a time (no more than five of them can be Mac).

For more information, you can refer to the Apple Support article, View and remove your associated devices in iTunes.