How is the word "New York" a synecdoche?
Without context, it's hard to tell.
A synecdoche is using a part of something to represent the whole; for example, saying "wheels" to mean car. So "New York" could be a synecdoche if you used to mean the New York Yankees, like in the following sentence, "New York won the World Series."
The phrase alone, however, is not a synecdoche, because it's impossible to tell what it's being used to stand for.