Also, to those who developed the doctrine (and those who still believe it as Aristotelians) the Father and Son are not identical with God precisely because God is a Substance while the Father, Son, and Holy Spirit are persons, which is an entirely different category of object.
As an analogy, two rocks may both be granite but obviously neither one is identical with granite, nor is one rock identical with the other. You can paint one rock blue and bury it in your yard and carve the other one into a statue. They have different characteristics, but each one is granite, in what I consider to be a perfectly natural sense of the word “is.”
You might say that despite being two separate things, both are examples of the same substance, namely granite. According to the Aristotelian philosophy developed by Christian theologians, it would be more precise to say that they are of similar Substance. Although you could say (somewhat imprecisely) that the Substance as well as the substance of each rock is granite, they are clearly not composed of the same granite, but of two bits of granite. The Substances are therefore similar, but not identical.
The Father, Son, and Holy Ghost, however, have the same Substance. The Substance of the Father is identical to the Substance of the Son is identical to the Substance of the Holy Spirit. Nevertheless, the Father is a person, not a Substance. Nor is the Father the same person as the Son or the Holy Spirit, or Holy Spirit the same person as the Son. They are like three pebbles composed not of similar pieces of granite, but of the same granite. How that happens is what Aquinas, for example, considered a mystery, since nothing like that is possible with physical things, but the phenomenon itself was considered explicable.
The problem is that when you read me saying “They are like three pebbles composed not of similar pieces of granite, but of the same granite,” you imagine that I mean the same molecules and atoms, the same quarks and electrons, somehow existing in three places at once, but pre-modern Aristotelians had no concept of atoms or quarks (Democritus notwithstanding). To them, what made granite granite was not the molecular structure of atoms of silicone and oxygen, but something abstract and nearly mystical, more akin to Justice or Square-ness than to something like an atom. That’s what Substance was, and without that, the whole thing becomes nonsense.