This saying means that you can't have something and also have its benefits. For example, you can't have a cake for a birthday and then eat it, because if you eat it then you don't have a cake anymore. So this saying is telling us that you can't have something and also get to use it or benefit from it—you have to choose one or the other.