Ukraine gov't specifically asked for it, publically. And of course, Russia government responded with anger. "Publicity" is naive. Unquestionably what Elon is doing now is provocative to Russia (and the handful of pro-Russia countries), but at a time when most places don't want to be friends with Russia, it's great PR but more importantly, it has real effects for people on the ground. It sends materialistic support and and condemnation which encourages others to follow suit.