Each state has different jurisdictional requirements. New York has specific requirements as to how you can file in NY but the issue of custody and support are governed by different law which is the same through out the country. Jurisdiction over custody and support is based on wherfe the children lived for the previous 6 months. You should contact a lawyer to see how this applies in your case.
Whoever files first as long as the state has jurisdiction has the case heard in that state (for divorce purposes). However, if the children were out of the state for 6 months or more before the divorce was filed then the state where the children resided for those 6 months has jurisdiction over custody and visitation.