Stir zucchini, water, salt, and basil together in a pot; bring to a boil, reduce heat to medium-low, and simmer until zucchini is tender, about 15 minutes.
Pour zucchini mixture into a blender no more than half full. Cover and hold lid down; pulse a few times before leaving on to blend until smooth. Puree in batches.
Whisk warm milk, flour, and salt together in a bowl until smooth.
Melt butter in a skillet over medium heat. Cook and stir onion in melted butter until translucent, 5 to 7 minutes.
Pour pureed zucchini and milk mixture into the skillet; bring to a boil while stirring continually. Season with pepper.