You also CAN consider a white pawn on e3 and a white pawn on d3 to be different kinds of pieces, because one of them is only allowed to move to e4 and the other is only allowed to move to d4.
But it is also POSSIBLE to construct the rules in such a way that all pawns share the same rules, and location and owning player are treated as accidental, rather than essential, properties.
You also CAN consider a white pawn on e3 and a white pawn on d3 to be different kinds of pieces, because one of them is only allowed to move to e4 and the other is only allowed to move to d4.
But it is also POSSIBLE to construct the rules in such a way that all pawns share the same rules, and location and owning player are treated as accidental, rather than essential, properties.