I'm applying for my masters in the field of computer science. I observed that most universities in Europe ask for a degree in computer science or a related course. I want to change my field from Electronics to Computer Science. so are they closely related and can i apply these CS courses?
This depends very much on your electronics degree. Most universities will ask for a certain amount of credits of certain subject (e.g. programming, data bases etc).
With electronics you will most likely have the basis and low level parts (math, architecture of cpus etc) well covered but you might have a gap in the more computer related areas.
The best way is possibly to informally ask where you want to apply to (attaching a syllabus of the courses you have taken). Some universities might also offer additional courses in order to catch up if you are short on some prerequisites.