Grease a 9×13 baking pan with butter or cooking spray and set aside.
Melt butter and marshmallows in a large saucepan over medium heat, stirring until marshmallows are melted.
Reduce heat to low and stir in cake mix.
Mix in rice krispies and stir until combined.
Pour into prepared baking pan and press down until even (spraying your hands with cooking spray or using parchment paper works best to get them firmly pressed into the pan.)
Allow to cool completely.
Frosting
Using an electric mixer, mix butter and cream cheese until combined.
Mix in vanilla extract
Gradually add in confectioners sugar until creamy.
Spread over rice krispie treats.
Garnish with shredded coconut flakes and chopped walnuts if desired.