UML Diagram are imporant because it help the person to understand the relationship
and dependency
between different class present in the code(Class Diagram).
Flow of the program(Sequence Diagram , Activity Diagram). Help to improve the program architecture etc.
And read about different type of UML diagram you will get more information.