Purpose-designed pike tubes are the safest way to retain pike for short periods, either to allow a fish which is in distress to recover, or to perhaps retain a pike prior to weighing or being photographed.
Either way, the tube should be staked out so it can not collapse on the fish and it should be inspected regularly and retained for the minimum possible time.