Companies and people record IP addresses for lots of reasons.
Think of your IP address the same way you do your home address. It tells people who you are and where you're from. Anyone looking to monitor what you do online needs to log your IP address to keep ***** of you.
Ever search for something on Google and then see advertisements for that very thing all over the place? It's because an advertising company logged your IP with "*****ing cookies" and uses that information to try and sell you things.
Similarly, governments, businesses and internet service providers might ***** your IP to see what you're doing online and to make sure you aren't breaking any laws or stealing anything they own. Anyone who has been prosecuted for downloading copyrighted content was caught when law enforcement started *****ing their IP address.
It's generally a good idea to try and keep your IP anonymous. The main options out there are web proxies and VPNs. Proxies only change your IP in your browser and don't provide any additional security, but are great if you're trying to access blocked websites. VPNs are programs you can download that reroute your connection through remote servers. VPNs offer faster speeds than proxies and both randomize your IP and encrypt all of your data. There are a lot of good options out there, it really depends what your needs are.