SPARK-2761 refactor #maybeSpill into Spillable

Moved `#maybeSpill` in ExternalSorter and EAOM into `Spillable`.
Better to call this `releaseMemory` or `releaseMemoryForThisThread` to be more explicit. We do something similar in `MemoryStore.scala`