How to add pages in wordpress using codes?

is_page() checks if page is being displayed, it has nothing to do with checking if page exists at all in installation.

You likely want get_page_by_path() or get_page_by_title() instead.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)