Let $A$ be a ring (commutative with $1$),if $X=Spec A$ we want to attach a sheaf of rings to $X$. If $f\in A$, $D(f)=X\setminus V(f)$ is an element of the base and we define $$\mathcal O_X(D(f)):=A_f$$
I've problems to show that $\mathcal O_X(\cdot)$ is well defined on the set $\mathcal B=\{D(f)\,:\, f\in A \}$. If $D(f)=D(g)$, then it is easy to show that $A_f\cong A_g$, but these two rings are not the same, so we have that $\mathcal O_X(D(f))\neq \mathcal O_X(D(g))$ even if they are isomorphic. Textbooks say "we can identify $A_f$ with $ A_g$" but what they exactly mean with the word "identify"?