Because the card *was* “exiled this way”. This specific type of case tends to trip people up because ‘exile’ has two related, but distinct meanings–it's both a keyword action and the name of the zone that action normally sends things to.
When
Declaration in Stone says " exiled this way“ it does not mean ”that were put into the exile zone this way“. It means ”That
Declaration in Stone successfully performed the action ‘exile’ upon." Declaration in Stone
did perform the action known as ‘exiling’ upon the commander. That Commander may not have ended up in the zone that that action normally results in the card moving to, but that doesn't change the fact that the action was indeed performed upon it.
This distinction can be seen more clearly with a different keyword action that's used in a similar manner: “destroy”. Compare
Declaration in Stone to
Fumigate. If you use
Fumigate to destroy a commander, and its controller chooses to put that card in the command zone instead of letting it go to the graveyard, you still gain a life for it, because
Fumigate destroyed it. It didn't go to the graveyard as a result of that destruction, but it was still destroyed. The same goes for
Declaration in Stone, only with different, slightly more confusing terminology.
If an effect cares about where the cards it's performing actions upon ends up, it will say so–see
Terastodon for an example.