Let's assume we have the punctured affine scheme $\mathbb{A}^2\setminus \{(0,0)\}$. Then we glue an affine line $\mathbb{A}^1$ to this along let's say $x$-axis and $\mathbb{A}^1\setminus \{0\}$. I can explain that the result is a scheme. My question is what scheme is it? Is it $\mathbb{A}^2$?
The reason why it is a scheme: First if you consider $\mathbb{A}^2\setminus \{x=0\}$ and glue $\mathbb{A}^1$ to it along $x$-axis and $\mathbb{A}^1\setminus \{0\}$. We get an affine scheme. Because we are gluing two affine schemes along a subschemes that is closed in one of them. (See this.). Now $\mathbb{A}^2\setminus (\{x=0\}\cup \{y=0\})$ is an open affine in this affine scheme. Now we can glue to this the affine scheme $\mathbb{A}^2\setminus \{y=0\}$ along the open subschemes $\mathbb{A}^2\setminus (\{x=0\}\cup \{y=0\})$. You get exactly what I described in the previous paragraph.
The point is that in order to get what I am asking for, you need two pushouts of schemes. One along a closed subscheme and the other one is just standard along open subscheme. If you do the open one and then the closed one you get what I described in the first paragraph. If you first glue the closed one and then open one you should get the same thing but I proved in the second paragraph that it is a scheme.