How to customize dynamic_sidebar rendering? [closed]

You may add before as well as after class to the sidebar when you define it into functions.php.

<?php $args = array(
    'name'          => __( 'Sidebar name', 'theme_text_domain' ),
    'id'            => 'unique-sidebar-id',
    'description'   => '',
        'class'         => '',
    'before_widget' => '<li id="%1$s" class="widget %2$s">', //You can change class/id here
    'after_widget'  => '</li>',
    'before_title'  => '<h2 class="widgettitle">',
    'after_title'   => '</h2>' ); ?>