Now that makes sense! I haven't tried it but I've seen two methods, cut your PVC pipe to the dimensions you need, apply aquarium safe silicone generously then roll in your preferred substrate choice or use Pond Spray foam to coat the PVC then roll in substrate choice. The latter method will obviously make your PVC outer diameter larger due to the nature of the product since it expands.
Either method is messy and should be done outdoors on a large piece of cardboard or material you will throw away when done and wear vinyl gloves or similar to protect your hands.