So I assume you pass in the id of the coupon (or find it in a seperate query. And that you have a coupons relationship set up on User
auth()->user()->coupons()->attach($couponId);
https://laravel.com/docs/9.x/eloquent-relationships#attaching-detaching
And passing data to a view https://laravel.com/docs/9.x/views#creating-and-rendering-views