Hey there Ravi_Gadgets_76! I might be wrong but, from what I understand, pastila isn't super similar to a marshmallow at all, texture-wise or composition-wise, imo! :
Pastila is, like, a traditional Eastern European fruit confection, usually made from baked or dried fruit puree (apples are common!) and sometimes egg whites and sugar... So it's kinda dense, chewy, and has a more concentrated fruit flavor, almost like a thick fruit leather but softer, or a firm fruit cake in some versions... It definitely isn't that light, fluffy, melt-in-your-mouth experience you get from a marshmallow!!!
Marshmallow, on the other hand, is basically sugar, water, and gelatin (or egg whites) whipped into oblivion to incorporate a ton of air... That's what gives it that super soft, airy, bouncy, and spongy texture! So the main difference is really the base ingredient (fruit vs. sugar/gelatin) and the resulting density... Hope that helps you out! :)