The form of a text is the type of text you are reading or watching. The form of Lord of the Flies is a novel. More specifically, it is an adventure novel and an allegory.
"While we're waiting we can have a good time on this island." He gesticulated widely. "It's like in a book." At once there was a clamour. "Treasure Island-" "Swallows and Amazons-" "Coral Island-" Ralph waved the conch. "This is our island. It's a good island. Until the grownups come to fetch us we'll have fun."
One particular genre of fiction is the adventure story, often set on a deserted island and featuring people being brave and resourceful, living a carefree existence and overcoming any obstacles. These books such as Robinson Crusoe and Treasure Island were extremely popular with young readers.
When writing Lord of the Flies, Golding was thinking of one such book in particular. The Coral Island by RM Ballantyne was written a century before Golding's book and features three shipwrecked boys called Ralph, Jack and Peterkin. Together, and with no help from adults, they construct shelters, find food, defeat pirates and generally have a great time while remaining friendly and supportive to each other. As a teacher of young boys, Golding found all this hard to believe and set out to turn this sort of fiction on its head.
An allegory is a narrative which has a symbolic and deeper level of meaning. Characters, setting, objects and colours, as well as having a place in the story, also stand for or represent other bigger ideas. So in Lord of the Flies:
An allegory can be seen as a very long extended metaphor. The symbolic meaning of an allegory is often political (eg George Orwell's Animal Farm) or religious (eg CS Lewis' Narnia books); Lord of the Flies is both.