A method for controlling a brake system for motor vehicles and apparatus for performing the method