How to reinstall macOS? I have only Ubuntu 16.04 (no Partitions) running on my MacBook (My model is A1181) but I would like to install macOS, replacing Ubuntu. How should I go about doing this?
Boot your Mac holding down the Command and r keys. This should get you into Recovery Mode.

First get into disk Utility and delete the Ubuntu partition and format it as macOS Journaled HFS+. Once that is done quit out of disk utility and click on Reinstall MacOS.

It will connect to your network via WiFi (so if you can do ethernet, it will go faster) asking you for your WiFi password and proceed to install the version of macOS that your Mac came with.

Once macOS is installed you can log into the mac and then into the App Store and pick a later version of macOS that you want on your Mac if the one that was installed is not as up to date as you like.