Question 1
Is it possible to build a coffee machine control app or app to control light bulbs?
Answer
Yes. It is possible with Raspberry Pi. Their will be separate electronics involved to electrically turn on/off the power supplies etc. You will have to read more on controller circuits or ask your friend to help you. What you will be doing with the Raspberry Pi will be to provide an interface to control those devices, either manually or automatically.
You can make Pi a server and design the server interface using HTML/Java Script. Then you will have to program the GPIO pins with Python/any other language.
This will be a bit challenging. But if you do things patiently while learning the basics it will teach you alot of interesting and important things.
Question 2
Can i build an app which communicates with the rasppi via wlan?
Answer
Yes!!. Raspberry Pi can act as a server. You can access its ports remotely on wlan to get the work done. Or else, you can install a web server(such as nginx). Think of Raspberry Pi as just another computer with programmable input output ports. Then get into each section of your project. If I were to do a room-light-controller system I'll follow these steps.
Design the electronic circuit. A electronic switch which accepts a voltage input and turns the light on/off.
Connect the above circuit to Pi using GPIO and write 'drivers'. That is a function/program which accepts light number and command as arguments.(eg: switch_on(light1), switch_off(light3) etc) This will be simple GPIO programming.
Build the interface.. .
Make it accessible over wlan/eth0 etc.