I'd like to know if it is possible in Android 5 to include a slider (an app) into the status bar f.e. to adjust brightness, volume etc.? There are apps like Play Music which also provide a ui in the status bar?
You should have a look at Sticky Notifications, like this: http://www.laurivan.com/android-make-your-notification-sticky/
http://developer.android.com/guide/topics/ui/notifiers/notifications.html - this explains how to add controls to the notification. But due to its implementation i assume its not possible to add an actual slider, but you could go for +/- buttons.