Try a smaller jar and have the lid loose. If the jar is smaller, the octo will be able to cover it. From touching the loose lid, it will hopefully learn that it can be unscrewed. After it does it the first time, it will 'know' how to do it later.
i would reccommend that you slowly condition him towards the behavior you want. start with an open jar with the crab inside and no lid (smaller jar), then put the lid on but dont screw it. when he starts figuring that out gradually tighten the lid more each time.