Yes, you can do some training in a Piper and some in a Cessna.
Although it's not a great idea to keep swapping aircraft types, especially in the early stages of a PPL, where continuity is more important. However, you seem to be suggesting flying an initial period in a Piper, then switching to a Cessna. This is fine, will be beneficial from an experience PoV, you should find it interesting, but will probably add slightly to the cost of getting your PPL.
For licensing/test purposes, hours are hours, (as long as they are on correct class of aircraft), it doesn't matter which manufacturer or aircraft type they are flown on, or what time period you gained them over.