Since you have a Schengen visa, I would not expect any problem in New York but it's really something you should take up with the airline.
In Milan, things are a bit different. There is obviously no requirement to have a Dubai visa when entering the Schengen area and it's most likely that the border guards won't ask anything about that. Even holding a ticket out of the area is not formally required. But they can more-or-less ask you about anything and everything to evaluate your intentions.
So they might very well ask how long you want to stay, then where you will go next and at this point inquire about the ticket or the visa. I would not expect most landing interviews to go that far into details but it's possible (Italy reports that entry checks take 1 min on average for people with a visa like yourself, even less in other situations, which does not leave a lot of time for extensive questioning).
If it happens, having nothing to show could diminish your credibility and the notion that you could come without an onward ticket or a visa for your next destination or choose to waste time on all this during such a short visit might sound odd, so be prepared to explain why you are doing it that way. Or just do it before leaving New York to have some additional peace of mind.
In any case, they would refuse entry because they don't believe you and rule that the purpose of your stay and/or your intent to leave the Schengen area could not ascertained, not merely because you have no Dubai visa per se.