Because Anarchy ranges from the very left to the very right on the political spectrum. If you have a anarchistic society with only one type of anarchists that might work - e.g. all work together out of the good of their hearts and on the end of the day they all dance in a barefoot circle around a bonfire - or all people shoot each other and on the end of the day only the strong survive.
But in a society where people have different believes laws are necessary.