According to CNBC, SpaceX is funding Starlink in Ukraine, not the government:
"Musk reportedly told the Pentagon in October he would no longer finance the Starlink terminals in Ukraine as the country prepared to fight through the harsh winter months. However, the billionaire reversed course and did continue to fund the service."