Wikipedia has a full discussion of both
malware and
rootkits. Rootkits can be considered a specific type or class of malware. Both are undesirable software and usually difficult to remove. They also only primarily infect the Microsoft Windows family of operating systems.