I even have no idea how to add indefined amount of new objects into game(segments of snake in my case)
Use a list. Something like List<Polygon> segments = new ArrayList<Polygon>(), then a method that creates new segments. Judging by the code, I'd say you might be new to collections, so I would start here: http://docs.oracle.com/javase/tutorial/collections/index.html
Truthfully, if I were designing it I'd break things out into a Snake class that held a single Head and a list of Segment objects, but one thing at a time.