JuMP Multiple Models Design Question

Here is the documentation which explains the difference: Variables · JuMP.

Essentially,

using JuMP

m1 = Model()
@variable(m1, x >= 0)  # Makes a Julia variable "x" which points to the JuMP variable "x" in m1.

m2 = Model()
@variable(m2, x >= 0) # Changes the Julia variable "x" to point to the JuMP variable "x" in m2.

m1[:x]  # The JuMP variable "x" in m1
m2[:x]  # The JuMP variable "x" in m2

m1[:x] == x # false
m2[:x] == x # true