According to Tommy Phillips, the pastor of Watermark, a C&MA church in Tampa, FL (a branch of Evangelical Presbyterians), the disciples assume the figure is a ghost because water is an extension of the Abyss.
As he explains in his series starting in Genesis, all throughout the Old Testament, water is associated with the Abyss, and subsequently associated with the unknown, the underworld, with chaos and destruction. The Abyss is in place prior to the creation of the world, and is a recurring instrument of destruction in the Old Testament narrative. Flood destroys the world, God holds back the Red Sea for the Israelites but drowns the Egyptians, Nehemiah being told to submerge himself, Jonah being tossed overboard, etc., all the way up to the introduction of Jesus. The concept of voluntary baptism, the demon-possessed pigs running into the river, and this specific passage where they see someone walking on water, and they immediately think it is a ghost, is mentioned.
I can't link an article, as the sermon is online only as a series of podcasts.