It is a bit of a pain, but you must dink with the icon in multiple spots.
First, create an .ico file. Make sure that it has all the required formats for Windows: 16, 32, 48. I like to add a 256 as well. There are a lot of online icon editors you can use. I use GIMP.
Copy your .ico file to somewhere in your project. I keep the .ico under res://Icons/Windows
.
Second, open the Export dialog and set your icon under Application→Icon.
Third, open your main scene and make sure _ready() sets the icon (and window title!) properly. Something like:
func _ready():
if OS.get_name == "Windows":
OS.set_native_icon("res://Icons/Windows/app.ico")
else:
...
Finally, you need to generate a Windows executable from the export menu. Once you have the .exe, you need to manually change the icon to use your game’s icon. This requires a special tool. I use Resource Hacker (get the patch from rammichael.com/resource-hacker-fx too). Several other similar tools exist. Enjoy googling.
Good luck!