You can use the "Demolish" command to remove a building from a given spot, or remove just a single level from that building. You can also cancel it if you wish. This is how you remove buildings you no longer need, like the storage cache, or get back the resources that went into it's construction. You get 20% of the resources that went into the structure or level you removed.
If you demolish all the structures on a given planet, you then are able to abandon that planet. This is useful when you want to run away from an aggressive neighbor. You should have the planet you want to run too colonized first, though.